|
Cookbook /
DynamicTrailsSummary: Dynamic WikiTrails with pagelist
Version: 1
Prerequisites: pmwiki 2.1
Status: experimental
Maintainer:
Questions answered by this recipeHow can I create a trail through the pages of a group without having a trailpage?
DescriptionAdd the following pagelist template formats to your Site.LocalTemplates: #grouptrailDynamic trail of form prev.Name | Group | next.Name
[[#grouptrail]]
(:if equal {$FullName} {=$FullName}:)[[{<$FullName}|+]] | [[{$Group}]] | [[{>$FullName}|+]](:if:)
[[#grouptrailend]]
#grouptrail2Dynamic trail of form <<prev | Group | next>>
[[#grouptrail2]]
(:if equal {$FullName} {=$FullName}:)[[{<$FullName}| « prev ]] | \
[[{$Group}]] | [[{>$FullName}| next » ]](:if:)
[[#grouptrail2end]]
Add to the group's GroupHeader or GroupFooter page the trail markup: For a trail of form PreviousPageName | Group | NextPageName (:pagelist group={$Group} fmt=#grouptrail :)
For a trail of form <<prev | Group | next>> (:pagelist group={$Group} fmt=#grouptrail2 :)
The trail markup will link to previous and next pages in the group, and to the group's homepage. The group's homepage does not need to contain a list of pages, the pagelist markup is generating the trail links. Variation: fmt=#nextontraildynamic trail of form NextPageName link
[[#nextontrail]]
(:if equal {$FullName} {=$FullName}:)Next page: [[{>$FullName}|+]](:if:)
[[#nextontrailend]]
NotesRelease Notes
CommentsHow do you make sure that RecentChanges and GroupFooter don't show up in the navigation when using the Dynamic Trails recipe? ~Steve 6/5/06 Answer: Try using the list=normal option to PageList - Martin Fick June 05, 2006, at 11:24 AM
This worked for me: (:pagelist group={$Group} name=-RecentChanges,-GroupFooter fmt=#grouptrail :) ~Steve
Why the perhaps put it as part of the pagelist format template? HansB
See Also
Contributors |