Generating tabular output (examples): Difference between revisions

no edit summary
fts>Gero
No edit summary
fts>Gero
No edit summary
Line 10:
 
|include = {Some Template}:parm1
|table = ,,The first parameter<br>of the Template Call
|tablerow = bgcolor=#eeffee¦%%
{{#dpl:
|titlematch = Some Article %
Line 21 ⟶ 23:
|include = {Some Template}:parm1
|table = ,-,The first parameter of the Template Call
|tablerow = bgcolor=#eeffee¦%%
{{#dpl:
|titlematch = Some Article %
|include = {Some Template}:parm1
|table = ,-,The first parameter <br>of the Template Call
|tablerow = bgcolor=#eeffee¦%%
}}
A single '-' instead of a column name for the hyperlink to the article will suppress that column.
Line 31 ⟶ 35:
== B: just get one chapter ==
 
|include = #Chapter X
|table = ,,X
|tablerow = bgcolor=#ffeeee¦%%
{{#dpl:
|titlematch=Some Article %
|include = #Chapter X
|table = ,,X
|tablerow = bgcolor=#ffeeee¦%%
}}
 
Line 42 ⟶ 48:
== B2: one chapter, one line per article ==
 
|include = #dummy,#Chapter X
|table = ,,,X
|tablerow = ,bgcolor=#ffeeee¦%%
{{#dpl:
|titlematch=Some Article %
|include = #dummy,#Chapter X
|table = ,,,X
|tablerow = ,bgcolor=#ffeeee¦%%
}}
Using a dummy parameter (and adding an empty column header -- set the three commas at 'table=,,,X') leads to only ONE line per article. Not very clean, but it works.
Line 53 ⟶ 61:
== C: get two different chapters ==
 
|include = #Chapter X,#Chapter Z
|table = ,,X,Z
|tablerow = bgcolor=#ffeeee¦%%,bgcolor=#ffffee¦%%
{{#dpl:
|titlematch=Some Article %
|include = #Chapter X,#Chapter Z
|table = ,,X,Z
|tablerow = bgcolor=#ffeeee¦%%,bgcolor=#ffffee¦%%
}}
 
Anonymous user