[pmwiki-users] login visible, not edit etc

Tegan Dowling tmdowling at gmail.com
Wed Mar 26 11:27:46 CDT 2008


On Wed, Mar 26, 2008 at 11:21 AM, James Montaldi <j.montaldi at gmail.com> wrote:
> At the moment I'm using the default skin. But I might change that.  Does it
> matter? I thought the skin was just the look and feel.

In the default PmWiki skin template (in pub\skins\pmwiki\pmwiki.tmpl),
there's a section that looks like this:

<!--PageActionFmt-->
<div id='wikicmds'><ul><li class='browse'>      <a accesskey=''
rel='nofollow'  class='selflink'
href='http://www.pmwiki.org/wiki/Main/HomePage'>View</a>
</li><li class='edit'>      <a accesskey='e'  rel='nofollow'
class='wikilink'
href='http://www.pmwiki.org/wiki/Main/HomePage?action=edit'>Edit</a>
</li><li class='diff'>   <a accesskey='h'  rel='nofollow'
class='wikilink'
href='http://www.pmwiki.org/wiki/Main/HomePage?action=diff'>History</a>
</li><li class='upload'>    <a accesskey='ak_attach'  rel='nofollow'
class='wikilink'
href='http://www.pmwiki.org/wiki/Main/HomePage?action=upload'>Attach</a>
</li><li class='print'>     <a accesskey=''  rel='nofollow'
class='wikilink'
href='http://www.pmwiki.org/wiki/Main/HomePage?action=print'>Print</a>

</li></ul>
</div>

This is where the page actions displayed in the upper-right of the
default skin come from -- the links are 'hard-coded' into the skin
here.  There's a nifty, nifty feature that lets you suppress display
of this section, conditionally, from within the wiki (!):  That first
bit, <!--PageActionFmt--> is in the form of an html comment, but it's
also a section identifier used by the pmwiki scripts.

To suppress display of that section unless the user is logged in with
edit rights, have this somewhere on your page (or on your
GroupHeader):

(:if ! auth edit:)(:noaction:)(:ifend:)

Some skins have the identified sections that display Site pages,
instead of hard-coding features such as the header, this actions area,
etc. -- when that 's the case, you can modify how such  section of the
page looks and acts by editing the page, as well as by using
(:noheader:), (:noaction:), (:noleft:), etc.



More information about the pmwiki-users mailing list