On Tue, Feb 21, 2012 at 12:47 AM, Patrick R. Michaud <pmich...@pobox.com>wrote:

> The CondAuth() function does what you want:
>
>    if (CondAuth($pagename, 'edit')) { ... }
>

When using CondAuth() or other similar functions [1] it's important to
remember to place them as late as possible in your config.php to avoid
various caching issues which can be very difficult to troubleshoot
otherwise.

See http://www.pmwiki.org/wiki/PmWiki/LocalCustomizations#configphp-order.

-Peter

[1] ResolvePageName(), CondAuth(), PageTextVar(), PageVar(),
RetrieveAuthPage() or others -- basically anything that is likely to
require the reading of a page during the processing of the function.  (That
list of functions pasted from the link above.)
_______________________________________________
pmwiki-users mailing list
pmwiki-users@pmichaud.com
http://www.pmichaud.com/mailman/listinfo/pmwiki-users

Reply via email to