I&#39;ve been playing around with the DeleteAction recipe (<a href="http://www.pmwiki.org/wiki/Cookbook/DeleteAction">http://www.pmwiki.org/wiki/Cookbook/DeleteAction</a>) and it&#39;s working really well. I&#39;ve set it so that only high-privilege accounts can delete, and I&#39;ve also been using the suggestion on that page to use a javascript that requires you to click a confirmation button before deleting the page.<br>
<br>A further suggested amendment prevents the javascripted link from appearing unless you are logged in - the javascript contains the line<br>&lt;a onClick=&quot;return confirmSubmit()&quot; href=&#39;$PageUrl?action=delete&#39; accesskey=&#39;ak_delete&#39;&gt;$DeleteText&lt;/a&gt;
<br><br>And the config.php contains the lines<br>if ($LoginName == &#39;Logout&#39;)<br>{$DeleteText = &#39;Delete This Page&#39;;} else {$DeleteText = &#39;&#39;;}<code><br></code><br>I couldn&#39;t actually get that config.php amendment to work as written, although it does work if I use<br>
if( isset($AuthId) ) {$DeleteText = &#39;Delete page&#39;;} else {$DeleteText = &#39;&#39;;};<br><br>However what I&#39;d *really* like to do is to stop the javascripted link from appearing unless you are logged in *as a specific authorisation group*. So my question is: does anyone know of a variable I can use in the config.php to limit by auth group in this way? Or alternatively, is there a way of calling the $DeleteText variable from within the wiki page (say as an (:if:) statement in Site.PageActions, like<br>
(:if auth delete:) [[$DeleteText]] (:endif:)<br><br>Hopefully the above makes sense, I&#39;m very much learning as I go!<br>Michael.<br><br>