LocalTemplates
This page contains local "templates" for PmWiki's (:pagelist:)
directive.
Brief Syntax Explanation:
See also: Site.PageListTemplates, PageLists, Page Variables, Page Text 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
#bloglistfull
[[#bloglistfull]] (:div9 class=blogpost:) %p blogdate%{=$:blogdate}%% !! [[{=$FullName}|+]] (:include {=$FullName} self=0:) \\\ (:div9end:) [[{=$FullName}|(:if group Blog :)Comment (:else:) Kommentoi (:ifend:) ({=$CommentCount})]] (:if ! equal {>$Group}:)----(:ifend:) [[#bloglistfullend]]
#bloglistlinks
[[#bloglistlinks]] * [[{=$FullName}|+]] — {=$:blogdate} [[#bloglistlinksend]]
#ohjelmalista
[[#ohjelmalista]] * [[{=$FullName}|+]](:if ! equal {=$:Kuvaus} '':) [-- {=$:Kuvaus}-](:if:) [[#ohjelmalistaend]]
#ohjelmakartta
[[#ohjelmakartta]] (:div5 class='item {=$:Aika}' style='height:{=$:Pituus}px;':) [[{=$FullName}|+]](:if2 ! equal {=$:Kuvaus} '':)\\ [-{=$:Kuvaus}-](:if2end:) (:div5end:) [[#ohjelmakarttaend]]
#describe
[[#describe]] * [[{=$FullName}|+]](:if ! equal {=$Description} '':) - {=$Description}(:if:) [[#describeend]]
PmForm templates
#commentform
[[#commentform]] (:messages:) (:input pmform target=comments class=commentform:) (:input default request=1:) (:input default author "{$Author}" :) (:input textarea msg rows=10 cols=40:) \\ (:input submit name=post value="Lisää kommentti":) Nimi: (:input text author:) %comment% E-mail: (:input text name=email value='':) %% (:input end:) [[#commentformend]]
#commentpost
[[#commentpost]] (:template defaults where=bottom:) (:template require msg errmsg="Viesti puuttuu":) (:template require author errmsg="Nimi puuttuu":) (:template require email match='' errmsg='Jätä sähköpostiosoite tyhjäksi':) >>talkpost<< (:if false:) IP {$$UserIP} (:if:) %p sign%{$$CurrentTime}\\ {$$author} {$$msg} >><< [[#commentpostend]]