I have a good number of novice users that are creating pages dealing with the XML content that they work with. Unfortunately, a lot of the XML elements follow a dot separated naming convention. This does not translate well to wiki page creation. If have a lot of situations where users create a page like "Unhandled Case in 
para.text Element". Instead of creating the desired page, this creates a "Text Element" in the wayward group, "Unhandled Case In Para". To combat this, I created a custom Site/PageNotFound page (see below) that tries to determine if the group in the page request exists or not. If the group doesn't appear to exist, it generates additional warnings.
<br><br>My problem is that this approach does not work if the user is creating a page that is generated from a template. This happens off of the Issues page in MyGroup (see local/MyGroup.Issues.php below). In this case, there is no checking that happens, so my users can create new groups without warning.
<br><br>My questions are:<br><ul><li>Is there a way to add PageNotFound functionality to pages created from templates?</li><li>Is there an easier way to check the existence of a group besides &quot;(:if ! [ exists {$Group}.{$Group} or exists {$Group}.HomePage ] :)&quot;?
</li><li>Is there an easy way to identify the user adding the new page and do conditional processing based on their name?</li></ul>Regards,<br>Kurt<br><br>Site/PageNotFound <br><div style="margin-left: 40px;">(:nolinkwikiwords:)
<br>(:if name {$SiteGroup}.PageNotFound:)<br>-&gt; %green font-style:italic% This page contains the text to be displayed when PmWiki is unable to locate a requested page.&nbsp; Administrators can edit this page to change the message.
<br>(:if:)<br>(:if !group Category :)<br>&gt;&gt;important&lt;&lt;<br>The page &quot;{$RequestedPage}&quot; doesn't exist. &nbsp;<br>&gt;&gt;&lt;&lt;<br>(:if:)<br>(:if ! [ exists {$Group}.{$Group} or exists {$Group}.HomePage ] :)
<br>&gt;&gt;warning&lt;&lt;<br>It looks like the group &quot;{$Group}&quot; may not exist. \\<br>Please check that you didn't include an unintentional '''dot''' ('''.''') or '''slash''' ('''/''') in your link name.<br>&gt;&gt;&lt;&lt;
<br>(:if:)<br>(:if auth edit :)<br>Do you want to create the page you requested?<br>* %rel=nofollow% [[{$FullName}?action=edit | Create {$FullName}]] <br>(:if ! [ exists {$Group}.{$Group} or exists {$Group}.HomePage ] :)<br>
''''' - OR - '''''<br>Do you want to create a main page for the new group you requested?<br>* %rel=nofollow% [[{$Group}.{$Group}?action=edit | Create {$Group}.{$Group}]] <br>* %rel=nofollow% [[{$Group}.HomePage?action=edit | Create {$Group}.HomePage]]
<br>(:if:)<br>(:if:)<br></div><br>local/MyGroup.Issues.php<br><div style="margin-left: 40px;">&lt;?<br></div><div style="margin-left: 40px;">&nbsp;&nbsp;&nbsp; $LinkPageCreateFmt = &quot;&lt;a class='createlinktext'<br>&nbsp;&nbsp;&nbsp; href='\$PageUrl?action=edit&amp;amp;template=
Site.IssuesTemplate'&gt;\$LinkText&lt;/a&gt;<br>&nbsp;&nbsp;&nbsp; &lt;a class='createlink' href='\$PageUrl?action=edit&amp;amp;template=Site.IssuesTemplate'&gt;?&lt;/a&gt;&quot;;<br>?&gt;<br></div>