[pmwiki-users] Monobook new tab problem

Inigo Aldazabal Mensa ialdazabal at ehu.es
Tue Aug 22 11:25:37 CDT 2006


Hi,

Thanks all for your help and suggestions.

The ?action=browse&extraparam did the trick. Great!

To get the back-and-forth behavior between document view and discussion view
I created a Comments group following the recipe in
http://www.pmwiki.org/wiki/Cookbook/CommentPageLink (near the end, blue
text). Seems to work ok now.

Regards,

Inigo




Dominique Faure wrote:

> On 8/22/06, Inigo Aldazabal Mensa <ialdazabal at ehu.es> wrote:
>> Adam Breashears wrote:
>>
>> >
>> > Check your ak_view variable - you need different ones for each link in
>> > the monobook skin, otherwise it will think each link is in the same
>> > state.
>> >
>> mmm... changing it to say
>>
>> * %item class=browse accesskey='$[ak_view]'%[[{$FullName} | $[View] ]]
>> * %item class=browse accesskey='$[ak_preview]'%[[{$FullName}-other |
>> $[View-other] ]]
>>
>> does not change the described behavior.
>>
>> By trial error I got to the conclusion that is the action what sets the
>> state.
>>
>> Could I perhaps add a new action to pmwiki, equivalent to browse, so that
>> monobook skin could  deal with it? Is this doable or to complicated?
>>
> 
> Hi,
> 
> As initially designed, the tab link states are defined according to
> the page current action and the one given in the link definitions from
> Site.PageActions (no given action meaning action=browse). Thus, if you
> provide several links with no (aka. browse) or same action, they will
> be identically rendered.
> 
> To transform a bug(?) in a feature, and get the expected result, you
> may provide an additional url parameter which will help differentiate
> them as in:
> 
> * %item class=browse accesskey='$[ak_view]'%[[{$FullName} | $[View] ]]
> * %item class=browse
> accesskey='$[ak_preview]'%[[{$FullName}-other?action=browse&extraparam
> | $[View-other] ]]
> 
> You could also get an interesting side effect, in providing the
> following extra parameter:
> from={$FullName} as in (style definition omitted):
> 
> * [[{$FullName}-other?action=browse&from={$FullName} | $[View-other] ]]
> 
> and redefining $PageRedirectFmt in your configuration file to remove
> the edit action:
> 
> $PageRedirectFmt = "<p><i>($[redirected from] <a rel='nofollow'
>     href='{\$PageUrl}'>{\$FullName}</a>)</i></p>\$HTMLVSpace\n";
> 
> This way, browsing the "other" page would add a link back to your original
> page.
> 
> Hope this help,
> Dom






More information about the pmwiki-users mailing list