Recent Changes - Search:

Pagine di servizio

Gruppi

Pagine in allestimento

Strumenti

Domini correlati

PmWiki

pmwiki.org

edit SideBar

Page List Templates

  Categoria: Amministrazione


This page contains "templates" for Pm Wiki's (:pagelist:) directive. The Site.LocalTemplates? page can be created and used to store pagelist templates that are local to a site.

1.  Brief Syntax Explanation:

See also: PageLists, Page Variables, Conditional Markup, and Cookbook:PagelistTemplateSamples.

Use with page variables: = current item < previous item > next item

Conditionals used to structure pagelist output: (:if equal {<$Group}:) At beginning of list (:if equal {>$Group}:) At end of list (:if ! equal {=$Group} {<$Group}:) First item in group (:if ! equal {=$Group} {>$Group}:) Last item in group


2.  fmt=#default

The default template for pagelists when fmt= isn't specified.

[[#default]]
(:if ! equal {=$Group} {<$Group}:)

:[[{=$Group}/]] /:
(:if:)
: :[[{=$Group}/{=$Name}]]
[[#defaultend]]

3.  fmt=#bygroup

Display pages by group/name.

[[#bygroup]]
(:if ! equal {=$Group} {<$Group}:)

:[[{=$Group}/]] /:
(:if:)
: :[[{=$Group}/{=$Name}]]
[[#bygroupend]]

4.  fmt=#simple

A simple bullet list of page names.

[[#simple]]
* [[{=$FullName}]]
[[#simpleend]]

5.  fmt=#title

A simple bullet list of page titles. Use order=title to have them sorted by title (the default sort is by name).

[[#title]]
* [[{=$FullName}|+]]
[[#titleend]]

6.  fmt=#group

A bullet list of groups.

[[#group]]
(:if ! equal {=$Group} {<$Group}:)
* [[{=$Group}/]]
[[#groupend]]

7.  fmt=#include

Concatenate the text of pages in the list. (Note, this can be an expensive operation!)

[[#include]]
(:include {=$FullName} self=0:)
[[#includeend]]

8.  fmt=#traillist

[[fmt=#traillist]]
[[#traillist]](:if ! equal {<$Group} {=$Group}:)
(:if true:)%gray%>%%[[{=$FullName}|+]]%gray%<%% \
[[#traillistend]]

9.  fmt=#description

List pages and append the page's description if it exists.

[[#description]]
*[[{=$FullName}|+]]
(:if ! equal {=$Description} '':)
->'-''description:'' {=$Description}-'
(:if:)
[[#descriptionend]]

10.  fmt=#descriptiong

List pages / groups and append the page's description if it exists.

[[#descriptiong]]
* [[{=$FullName}|+]]: '-Gruppo [[{=$Group}|+]]-'
(:if ! equal {=$Description} '':)
->'-''description:'' {=$Description}-'
(:if:)
[[#descriptiongend]]

11.  fmt=#simplename

Simple bullet list of page names, without the Group name.

[[#simplename]]
[[({=$Group}/){=$Name}]] %red% | %% 
[[#simplenameend]]

 

Edit - History - Print - Recent Changes - Search
Page last modified on November 29, 2009, at 08:03 PM