[pmwiki-users] Planning for 2.2.0

Patrick R. Michaud pmichaud at pobox.com
Fri Sep 22 13:37:53 CDT 2006


On Fri, Sep 22, 2006 at 02:19:46PM -0400, Henrik Bechmann wrote:
> Patrick,
> 
> Remind me of the syntax for a page variable that will resolve for the 
> browsing page? {$:Group}?{$.Group}? 

I haven't fully decided yet.  It's likely to be one of

    {.$Group}
    {/$Group}
    
> (As long as it is a simple change 
> from the current, it shouldn't be that hard for admins to fix, as there 
> aren't many Site. pages compared to the rest).

I'm more worried about skins that rely on the existing behavior, and
that have added a lot of custom pages for actions and views.

> A component  that could be compatible with the {!TextVar} approach might 
> be to introduce a (:scope local|global:) (:scopeend:) directive, which 
> could apply to either/both page and text variables. 

I've thought about this a lot, but it really has to be able to understand
nested scopes in order to work properly, and that makes it really
hairy to implement and get to work correctly in all contexts.

The approach I'm looking at right now is to do a scan for
{$...} and [[...]] text that isn't already fully qualified, 
and fully qualify each before inserting them into the markup text.
For example, if Group.ABC has things like

    {$Name}  
    [[link]]  
    [[PmWiki/Foo]] 
    WikiWord
    {AnotherPage$:xyz}

then these will be automatically converted to

    {Group.ABC$Name}          
    [[Group/link]]  
    [[PmWiki/Foo]]               # note, unchanged, already fully qualified
    Group/WikiWord               # changed only if wikiwords enabled
    {Group.AnotherPage$:xyz}

so that they're fully qualified when rendered.  And, of course,
the conversion will know to honor [=...=] and [@...@] escapes, etc.

Pm




More information about the pmwiki-users mailing list