Examples/Parameter: multisecseparators (example 1): Difference between revisions
imported>FrozenPlum (Created page with "<noinclude>{{note|Please '''do not edit''' this page unless you're wanting to edit the manual itself, it is an example included in the manual.|error}}</noinclude><!-- This is the example preloaded for testing, press "Show Preview" to see the example working (at the bottom of the page). If you save this page, it saves as a new section at the bottom of your '''User:Username/Sandbox''' --> ==Example== This will create a list of articles in Category:Primary Module (ma...") |
imported>FrozenPlum m (fix inconsistent char use) |
||
Line 17:
listseparators = ¶{|class="wikitable sortable" ¶!colspan=3|Fields cannot be formatted within the include¶|-¶!Page ¶!Name ¶!Purpose,¶|-,¶|-¶|class="dpl-dark-background" colspan=3|¶|-,¶|}
secseparators = ¶|,,¶|class="dpl-orange-background"|,
multisecseparators = ,
</dpl>
</pre>
|
Revision as of 07:14, 11 April 2022
Example
This will create a list of articles in Category:Primary Module (manual pages) that don't have "volume" or "page selection" in the title, and that use the "DPL parameter" template. It includes the page name (linked to the page) and includes the values of the "name" and "purpose" parameters (from the "dpl parameter" template) used on each page, with included "purpose" text limited to a count of 50 characters. Since the "DPL parameter" template is used multiple times on the same article, it lists the first and then each subsequent template use with its corresponding values. The listseparators
prameter sets the table wikitext along with an extra row between seprate articles colored dark (navy), secseparators
is used to add more columns for each section found and color the first instance of template use orange, and since multisecseparators
puts a tag between multiple transcluded parts which refer to (use) the same template or chapter, it colors the rest of the inclusions of the "dpl parameter" template values, after the first, to (light) blue.
<dpl> category = Primary Module nottitlematch = %volume%|%page selection% uses = Template:DPL Parameter include = {DPL manual}:[[%PAGE%]],{dpl parameter}:name:purpose[50] mode = userformat listseparators = ¶{|class="wikitable sortable" ¶!colspan=3|Fields cannot be formatted within the include¶|-¶!Page ¶!Name ¶!Purpose,¶|-,¶|-¶|class="dpl-dark-background" colspan=3|¶|-,¶|} secseparators = ¶|,,¶|class="dpl-orange-background"|, multisecseparators = ,¶|-¶|¶|class="dpl-blue-background"| </dpl>
Result
<dpl>
category = Primary Module nottitlematch = %volume%|%page selection% uses = Template:DPL Parameter include = {DPL manual}:%PAGE%,{dpl parameter}:name:purpose[50] mode = userformat listseparators = ¶{|class="wikitable sortable" ¶!colspan=3|Fields cannot be formatted within the include¶|-¶!Page ¶!Name ¶!Purpose,¶|-,¶|-¶|class="dpl-dark-background" colspan=3|¶|-,¶|} secseparators = ¶|,,¶|class="dpl-orange-background"|, multisecseparators = ,\n|-¶|¶|class="dpl-blue-background"|
</dpl>