[pmwiki-users] Help using Custom markup plus ParseArgs

Dominique Faure dominique.faure at gmail.com
Thu Apr 6 04:09:01 CDT 2006


On 4/6/06, Octocias <octocias at googlemail.com> wrote:
> Hi All,
>
> I've been looking at:
>
> http://www.pmwiki.org/wiki/Cookbook/ParseArgs   and
> http://pmwiki.org/wiki/PmWiki/CustomMarkup
>
>
> I'm having problems understanding  how to combine boths sets of help to
> acheive what I want.
>
> I'd *like* to do this:
>
> In one WikiPage, I would have fragments of content representing an entire
> "content set".. e.g. I plan to host a profile of all my friends and family.
> A single person would have one WikiPage dedicated to them. That WikiPage
> would contain (for example): "surname", "summary", "full profile",
> "ThumbnailOnly", "PersonalLink", etc.
>
> If I wanted to make a single page filled with thumbnails of people I would
> like to do this:
> (:PersonData person="jason hattingh" content=ThumbnailOnly:)
> (:PersonData person="ayn rand" content=ThumbnailOnly:)
>
> ..etc..
>
> If I wanted to make a single page filled with ROWS dedicated to summaries of
> people I would like to do this:
>
> (:PersonData person="JasonHattingh" content=summary:)
> (:PersonData person="AynRand" content=summary:)
>
> ..etc..
>
>
> The result is that the args are used to construct a link which reads between
> "specified section start" and "specified section end"
> I have yet to learn to use PHP, but I imagine that I would interpret the
> args in this (pseudo code) way:
>
>
> // construct part of the wiki link e.g. People.JasonHattingh
> $Pagename = "People." + $args['person']
>
> // construct the bookmark extraction specification:
> $Section = "#" + $args['section'] + "S" + "#" + $args['section'] + "E"
>
>
> // Piece it together:
>
> $FullLink = $PageName + $section
>
> some_incluce_command( $FullLink );
>
>
>
> Ok, that's it.. I hope it's clear enough.. Does this seem a good way to do
> it? I am quite worried that I may be barking up an inefficient tree.
>

Why don't you try with (:pagelist:) using a specific template?

Regards,
Dom

--
The difference between theory and practice in theory is much less
than the difference between theory and practice in practice.
 — Randal L. Schwartz




More information about the pmwiki-users mailing list