|
Cookbook /
PageListWikiTrailSummary: Enable a WikiTrails markup to use a (:pagelist ... :) directive
Version: November 2005
Prerequisites:
Status:
Categories: Administration, WikiTrails
GoalTo enable a WikiTrails markup to use a (:pagelist ... :) directive, either directly inside a WikiTrails markup <<(:pagelist ...:)>>, or when it forms part of the index page referred to in a normal WikiTrails instruction. Solution
DiscussionThis test version is a modification of PmWiki's trails.php (pmwiki-2.0.devel26) It should be downloaded to the cookbook folder. The original "trails.php" should be disabled, and this new one included by putting $EnableWikiTrails=0;
include_once("cookbook/pagelisttrails.php");
in the config.php file. To use the script, add one or more (:pagelist ...:) directives to the index page specified in a normal WikiTrails markup. The script will use all pagelist directives, plus any other bulleted links on the page, to construct the trail. Alternatively, put a pagelist directive directly in the WikiTrails markup, in the form <<(:pagelist ... :)>>. This method will produce just the 'previous' and 'next' links, and will align them to the left and right. Note: trail links will be in 'simple format', using the full pagename, irrespective of the 'fmt' option specified. The 'list' option will still apply.
Alternative way to create trails without an index page:The DynamicTrails recipe explains how to do create trails with a pagelist template and without installing any cookbook scripts or extra markup. See Also
ContributorBugs
Because on the page PREVIOUS>> <<NEXT is produced (if I'm correct: since PMWiki2.0-beta18). Han, 05 feb 05
WishlistIt would be nice if the list excluded the groupname AND used the {$title} instead of the {$name} to list the pages. To make things perfect spacedwikiwords in the list would look much better. Han, march 13 05 at 15.20 CET If you are directly embedding the pagelist in each page you can do this with DynamicTrails.
|