On 9/01/14 6:35 PM, Petko Yotov wrote:
John Rankin writes:
> John Rankin writes:
>> On 8/01/14 12:31 PM, Petko Yotov wrote:
...
> 2. $pagename is not in the scope of the callback function,
...
Sorry, I over-simplified. In practice, the $LinkTidy array is defined
once
at the start and then referenced as a global variable several times in
different places to do the actual tidying. So at the time $LinkTidy is
defined, the code may not know the $pagename. Potentially, the
tidying can
apply to multiple different $pagename values as it assembles several
wiki
pages into one output.
Do I use \$pagename instead?
Once again, $pagename is not automatically in the scope of the
callback function. If you want to use $pagename in the callback, it
must somehow get into that callback. If it does, yes, when defining
the callback, use \$pagename.
Of course; you said that before. Stupid me. Apologies.
Thanks again
--
John Rankin
_______________________________________________
pmwiki-users mailing list
pmwiki-users@pmichaud.com
http://www.pmichaud.com/mailman/listinfo/pmwiki-users