[pmwiki-users] links automatically display page title

Markus Heinzer keusen at gmail.com
Sat Jan 15 17:12:37 CST 2011


Am 15.01.2011 17:56, schrieb Patrick R. Michaud:
> On Sat, Jan 15, 2011 at 03:34:56PM +0100, Peter Bowers wrote:
>> So something like this should theoretically work (just changed the
>> pattern to not look for "|+"):
>>
>> Markup('[[title', '<[[|',
>>    "/(?>\\[\\[([^|\\]]+))\\s*]]/e",
>>    "Keep(MakeLink(\$pagename, PSS('$1'),
>>                   PageVar(MakePageName(\$pagename,PSS('$1')), '\$Title')
>>                  ),'L')");
>>
>> Of course you're going to have to disable the "[[" rule so they don't
>> fight over the free links...  Search for DisableMarkup() for that -- I
>> think it's as simple as:
>>
>> DisableMarkup('[[');
>
> Since the new markup is guaranteed to act before the "[[" markup,
> it's not necessary to disable "[[" (but it doesn't hurt to
> do so).
>
> Pm

this works perfectly nice! thanks a lot. i'm once more impressed about 
the speed and the appropriateness in this mailing-list.
mh



More information about the pmwiki-users mailing list