[pmwiki-users] (How) can I add optional information to a wiki trail?

Martin Spindler spindler at isg.cs.uni-magdeburg.de
Mon Jun 18 06:21:11 CDT 2007


Hi list,

since nobody seems to know a solution for my problem, I found one by 
myself :-) I just patched pmwiki.php and added one single line of code 
to " function PageVar($pagename, $var, $pn = '')  "

And this is the line of code:   if ($var == '$detail') return 
$PCache[$pn]['detail'];
which needs to be put between

 } else { $group = ''; $name = ''; }

and

  if (@$FmtPV[$var]) return eval("return ({$FmtPV[$var]});");

Now I can use {<$detail}, {=$detail} and {>$detail} in my page list 
templates to access the additional arguments (see my original post for 
an example wiki trail).

A working example can be found on: [1]

@pm: Do you think, you could integrate this into the head-version of PmWiki?

Cheers,
Martin.
[1] 
http://wwwisg.cs.uni-magdeburg.de/~spindler/wiki/home/travel/Test/WikiTrailArguments
     (The edit password is 'test'.)


Martin Spindler wrote:
> Hi list,
>
> sorry for asking so many questions.
>
> I would like to define a wiki trail with additional information, e.g.
>
> in the Singapore/MyFirstDay wiki page I have something like this:
>
> (:if false:)
> * [[Pics.Singapore-img002]]  Arrival at Changi-Airport
> * [[Pics.Singapore-img008]]  First time eating with chopsticks
> * [[Pics.Singapore-img012]]  Bla bla
> * [[Pics.Singapore-img009]] Doof dumm bla
> (:ifend:)
>
> And now I would really like to use the additional comments in some page 
> list templates. (How) is that possible?
>
> Cheers,
> Martin.
>
>
>
> _______________________________________________
> pmwiki-users mailing list
> pmwiki-users at pmichaud.com
> http://www.pmichaud.com/mailman/listinfo/pmwiki-users
>   






More information about the pmwiki-users mailing list