PageListTemplates-Talk

I've added a PITS entry for a proposed addition to the (:template ...:) markup. More specifically, I think we should be able to say (:template ! first {=$Group}:) in order to eg. add markup before each item except for the first. Currently to achieve this you need to use (:if equal {=$Group} {<$Group}:), which seems a bit clumsy as most other similar markup has been deprecated. The PITS entry also includes the required changes to scripts/pagelist.php. —Eemeli Aro July 29, 2009, at 08:19 AM

Questions

Can template last be used when template each includes another pagelist?

Sometimes I notice that the page count that I normally show at the end of my outer pagelist appears right before (instead of right after) the display of the final page. If what I'm doing is not supported, is there some kind of conditional or other markup that can be used within a template in lieu of template last that might work where template last fails?

I am not aware that Template Last should appear before Template Each. Can you demonstrate it here or elsewhere on the wiki? --Petko March 20, 2016, at 06:12 PM

How can I achieve adding a table column only when pagelist outputs something?

There is now a wrap option to (:pagelist:) to allow it to return the markup to the enclosing page, as opposed to rendering it standalone.

Can I use page variables, or even PTVs, in the (:template defaults:) section?

They seem not to work as of 2.2.6. I'd like to do (:template defaults group={*$Group}:) or similar. Maxim? October 11, 2009, at 08:24 AM

Please see, and vote for PITS.00986

Is it possible to transport a link to a uploaded PDF file via PageListTemplate to a pagelist?

I need to manage a lot of standards / codes in a table. To avoid working in a big advanced table I like create a topic for each standard. This topic will have the standard in PDF as an attachment. On this topic I add a few page variables (Name: description: file: etc.)
All these topics I want to collect in a pagelist build from a PageListTemplate.

The user of the wiki shall open the standard direct out of this list and not need to run over the topic.

My try of a template:

(:file:ExampleFileName.pdf:)(:issuedate:2017-09-04:)(:description:an example for the pagelist output:)
>>comment<<
[[#standardlist]]
(:template first:)
(:table:)
(:template first {=$Group}:)
(:cellnr:) Topic
(:cell:) standard
(:cell:) issue date
(:cell:) description
(:template each:)
(:cellnr:)[[{=$FullName}]]
(:cell:)Attach:{{=$FullName}$:file}
(:cell:){{=$FullName}$:issuedate}
(:cell:){{=$FullName}$:description}
(:template last:)
(:tableend:)
[[#standardlistend]]
>><<
(:pagelist fmt=#standardlist group=PmWiki name=PageList* count=4:)

(:template first:)

(:template first {=$Group}:)

Topic standard issue date description

(:template each:)

{=$FullName}? Attach:{{=$FullName}$:file} {{=$FullName}$:issuedate} {{=$FullName}$:description}

(:template last:)

Topic standard issue date description
PmWiki.PageLists Attach:
PmWiki.PageLists-Talk Attach:
PmWiki.PageListTemplates Attach:
PmWiki.PageListTemplates-Talk Attach:ExampleFileName.pdf 2017-09-04 an example for the pagelist output

Andreas 29.01.2010

How does this look?

In a pagelist template I want to be able to supplement a parameter, e.g.

(:template defaults name=-SideBar,-RecentUploads,-RecentChanges,{$$name}:)

However I still see the excluded names returned? Is this possible? simon September 04, 2017, at 03:11 AM

No, but you can have (:template defaults list=normal:) to exclude most but not SideBar, or add your own "list=mylist" patterns, eg
$SearchPatterns['mylist'] = array('servicepages'=> '!\\.(SideBar|RecentUploads|RecentChanges)$!');
See $SearchPatterns. --Petko September 04, 2017, at 04:40 AM


This is a talk page for improving PmWiki.PageListTemplates.