[pmwiki-users] Conditional markup for permissions

Randy Brown randy at brownragfilms.com
Thu Jan 15 12:20:48 CST 2009

This works to test whether the current user has read access to the page:

(:if auth read:)

You can also check what the attributes are on a given page. For  
example, this, which requires MarkupExprPlus, shows "readable" if the  
first 7 characters in the read attribute is "@nopass"

{(if (test equal "@nopass" (substr "{*$PasswdRead}" 0 7)) readable;)}

Remember that depending on your set up, read access might be  
controlled by the group attributes and / or the page attributes.

Hope that helps,


On Jan 15, 2009, at 12:01 PM, James DeVain wrote:

> Hi,
> Is there any kind of conditional markup expression for
> whether or not a page has a certain permission set? I
> couldn't find anything at pmwiki.org.
> Something along the lines of:
> (:if enabled passwdread:)
> Yes, a read password is set for this page.

More information about the pmwiki-users mailing list