<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Nov 22, 2015 at 6:55 PM, Donald Z. Osborn <span dir="ltr"><<a href="mailto:dzosborn@gmail.com" target="_blank">dzosborn@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Experimenting with categories, and seems to be going well, but wanted to set the default page as Category.Categories rather than Category.Category or Category.HomePage. Did a group config file Category.php including the following lines but the site still wants to call Catagory.Category. Not the first group config I've done so thought it would be simple.</blockquote></div><br><br></div><div class="gmail_extra">In <a href="http://www.pmwiki.org/wiki/PmWiki/BasicVariables#DefaultPage">http://www.pmwiki.org/wiki/PmWiki/BasicVariables#DefaultPage</a> the definition of $DefaultPage makes specific reference to the importance of setting these variables (including $DefaultName) before any call to ResolvePageName() - presumably because it gets cached there.<br><br></div><div class="gmail_extra">If you look at pmwiki.php it first calls farmconfig, then config, then scripts/stdconfig which calls ResolvePageName and then calls scripts/pgcust which handles any per-group or per-page customization. Thus ResolvePageName is always called before any per-page or per-group customization.<br><br></div><div class="gmail_extra">Since you are already putting a conditional regarding the group name (which wouldn't be necessary if you were to keep it in the group customization file), why don't you put this part (setting of $DefaultName) in config.php instead of in the per-group customization script?<br><br></div><div class="gmail_extra">Do note that the conditional as you have it will not respond if someone has specified just "Category" as the groupname (since there is no period or slash coming after it). You might want to consider something like this:<br></div><div class="gmail_extra"><br>if (preg_match('!^GroupTest(?:[./]|$)!', $pagename))<br> $DefaultName = 'Xyz';<br><br></div><div class="gmail_extra">Hmmm... Even after I do this I find that MakePageName() is forcing the pagename to be GroupTest.GroupTest instead of GroupTest.Xyz. Shouldn't it be paying attention to the $DefaultName? I find this true regardless of whether I go to a url (?n=GroupTest or ?n=GroupTest.) or if I use an in-markup link ([[GroupTest.]]). Is this something I should put in PITS or am I not understanding how default group names are supposed to work or is something messed up in my system?<br><br></div><div class="gmail_extra">Regardless, hopefully this has peeled a couple layers of the onion away from the problem.<br></div><div class="gmail_extra"><br></div><div class="gmail_extra">-Peter<br></div></div>