[Pmwiki-users] Unwanted Autolinks with WikiWords Off

Patrick R. Michaud pmichaud
Fri Apr 9 11:14:04 CDT 2004


On Fri, Apr 09, 2004 at 11:30:18AM -0500, Eric Celeste wrote:
> I'm seeing some odd behavior and before I sink time into making it
> consistently reproducible I wondered if it was a known issue of some sort.
> 
> I have WikiWords turned off in most groups using this method...
> 
>   $group = FmtPageName('$Group',$pagename);
>   if ($group!='' && $group!='Main' && $group!='PmWiki')
>      $WikiWordCountMax = 0;
>
> The odd thing is that certain words, like "UThink", start sprouting the "?"
> of a wikiword anyway. 

Keep in mind that if $pagename is empty (i.e., if someone goes to the
pmwiki.php script without specifying a pagename), then $group will be
empty and WikiWords will be turned on for your default page.  You might
want to add something like

   if ($pagename=='') $pagename=$DefaultPage;

before the lines you gave above.

(PmWiki doesn't set $pagename to $DefaultPage until *after* loading the
config.php, to give the config.php script a chance to detect that no
page name was specified and to do something appropriate with it.)

Pm



More information about the pmwiki-users mailing list