[pmwiki-users] {$Action} broken?

Pico pmwiki at ben-amotz.com
Tue Aug 22 06:41:30 CDT 2006

Bart wrote:
> I like to use $Action for hiding and showing links in the PageAction menu
> and ran into odd behavior of (:if action ACTION:) at the bottom of
> http://pmwiki.org/wiki/Cookbook/ConditionalMarkupSamples and was able to
> track this down to $GLOBALS["action"] which is passed to $Action in
> pmwiki.php
> So if I modify the example from that section to:
> (:if ( ! action print ) :)
>   * %item class=browse accesskey='$[ak_print]'%[[{$FullName} | $[Print] ]]
> (:ifend:)
> and put $Conditions['action'] = '\$GLOBALS["action"]==\$condparm';
> in my config.php
> It doesn't work like expected. The print link doesn't disappear when I my
> URL ends with: ?action=print Which according to mentioned in the Markup
> samples should be the case. Somehow "print" gets  lost 
> To me this looks like a minor bug.
> Any suggestions?

How about using a skin page variable to test whether the current skin is 
print.  See PmWiki/PageVariables at "Custom Page Variables" for details.


More information about the pmwiki-users mailing list