00728: Pagelist exclude pages from trail

Summary: Pagelist exclude pages from trail
Created: 2006-04-26 20:52
Status: Closed - exists
Category: Feature
From: Pico
Assigned:
Priority: 44
Version: 2.1.5
OS: N/A

Description: Request to extend pagelist to exclude pages identified by reference to a trail.

This can now be done with the if="! ontrail TrailPage {=$FullName}" parameter.

(:pagelist group=PmWiki if="! ontrail PmWiki.DocumentationIndex {=$FullName}" fmt=simple count=5:)
----
(:pagelist group=PmWiki if="ontrail PmWiki.DocumentationIndex {=$FullName}" fmt=simple count=5:)

This request was articulated by Pm during some inadvertantly offlist discussions regarding my overly complicated attempt to extend the pagelist faq to cover pages in the PmWiki group that were not part of the DocumentationIndex trail:

Pico's message clarifies for me the value of having a "trail=-PageName" option to pagelist. I had wondered about the potential value of having an "exclude pages from this trail" option, but didn't recognize an application for it until just now.

Instead of having to maintain the extra pages in the DocumentationIndex in a >>comments<< section, we could have PmWiki.FAQ use two pagelist directives:

    (:pagelist trail=PmWiki.DocumentationIndex ...  :) 
    (:pagelist group=PmWiki trail=-PmWiki.DocumentationIndex ...  :) 

The first grabs pages from the trail, the second grabs any pages in the PmWiki group that weren't on the trail.

Similarly, at the bottom of the DocumentationIndex page we could do:

    !! Other PmWiki documentation pages
    (:pagelist group=PmWiki trail=-DocumentationIndex fmt=simple:)

and we'd get a nice bullet list of any pages in the PmWiki group that weren't already listed in the DocumentationIndex.

This would also be useful for categories -- a Category.* page could explicitly list some of the pages in the category (where order is important), and the Category.GroupFooter could contain:

    (:pagelist link=Category.{$Name} trail=-Category.{$Name}:)

which would display any pages in the category that aren't already listed on the category page.

Cooooool. I'll have to keep this in mind for a future upgrade. :-)

Yes, it would be cool, and I added this entry to help you keep it in mind. Pico

Another application for this, raised in the mail list thread Any chance to get a (:pagelist link=-Category.xy:) ? (4/26/06 by Daniel Hofer) is to assist in editing and maintaining a site by checking for pages that have not yet had a category added (or a particular category added) on a site (or group) where all pages are supposed to have categories.