List Info

Thread: PmWiki router posted to cookbook




PmWiki router posted to cookbook
country flaguser name
United States
2007-11-20 22:32:06
A router recipe has been posted to the cookbook at
http://www
.pmwiki.org/wiki/Cookbook/Router

Router allows a website's url structure to be different from
PmWiki's
group/page structure.


Development issue:

Router currently requires that it be executed before calling
pmwiki.php.  If
it's permissible to change the value of $pagename from the
config.php file,
I could make installation simpler and do everything from
config.php.

I've tried it, and it appears to work, but I don't
completely understand
what's going on in pmwiki.php(2.2.0beta63) lines 296-306, so
I'm reluctant
to do it that way.  These lines appear to filter and assign
a value to
$pagename just before the config files are included.

Any thoughts about the acceptibility of changing the value
of $pagename in
config.php?


_______________________________________________
pmwiki-devel mailing list
pmwiki-develpmichaud.com
http://www.pmichaud.com/mailman/listinfo/pmwiki-devel

Re: PmWiki router posted to cookbook
country flaguser name
United States
2007-12-16 09:45:43
On Tue, Nov 20, 2007 at 10:32:06PM -0600,
pmwikiusers.mmajordfgh.net wrote:
> A router recipe has been posted to the cookbook at
> http://www
.pmwiki.org/wiki/Cookbook/Router
> 
> Router allows a website's url structure to be different
from PmWiki's
> group/page structure.
> 
> 
> Development issue:
> 
> Router currently requires that it be executed before
calling pmwiki.php.  If
> it's permissible to change the value of $pagename from
the config.php file,
> I could make installation simpler and do everything
from config.php.
> 
> I've tried it, and it appears to work, but I don't
completely understand
> what's going on in pmwiki.php(2.2.0beta63) lines
296-306, so I'm reluctant
> to do it that way.  These lines appear to filter and
assign a value to
> $pagename just before the config files are included.
> 
> Any thoughts about the acceptibility of changing the
value of $pagename in
> config.php?

It's completely acceptable -- PmWiki is designed to allow a
config.php to
manipulate $pagename.  In fact, that's why some operations
in config.php
require doing a ResolvePageName() first -- PmWiki is making
it possible
for a config.php to do its own thing with pagename.

Pm

_______________________________________________
pmwiki-devel mailing list
pmwiki-develpmichaud.com
http://www.pmichaud.com/mailman/listinfo/pmwiki-devel

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )