Show templates parameters from an article (example): Difference between revisions
Content added Content deleted
No edit summary |
imported>FrozenPlum m (This may need to get merged elsewhere, or greatly expanded to be a better example, maybe with some other output formatting (for now, fix the example so it works)) |
||
(10 intermediate revisions by 6 users not shown) | |||
Line 1: | Line 1: | ||
{{DPL manual|section=Examples|subsection=Show templates parameters from an article}} |
{{DPL manual|section=Examples|subsection=Show templates parameters from an article}} |
||
The include parameter can be used to display the output value of a specific |
The include parameter can be used to display the output value of a specific parameter passed into a template used in an article, using the <code>{Template}:parameter</code> format. |
||
This example will show the subsection given to {{Tl|DPL manual}} used in the [[Criteria for page selection]] article: |
|||
<pre> |
|||
This example: |
|||
⚫ | |||
⚫ | |||
⚫ | |||
}} |
|||
</pre> |
|||
'''Result:'''<br> |
|||
<pre><nowiki>{{#dpl: |
|||
⚫ | |||
⚫ | |||
}}</nowiki></pre> |
|||
{{#dpl: |
|||
Would produce this output: |
|||
⚫ | |||
⚫ | |||
}} |
|||
[[Category:Miscellaneous examples]] |
|||
⚫ | |||
⚫ | |||
⚫ | |||
}}</code> |
Latest revision as of 05:45, 3 April 2022
|
Manual | Examples | Show templates parameters from an article |
The include parameter can be used to display the output value of a specific parameter passed into a template used in an article, using the {Template}:parameter
format.
This example will show the subsection given to {{DPL manual}}
used in the Criteria for page selection article:
{{#dpl: |title=Criteria for page selection |include={DPL manual}:section }}
Result:
{{#dpl: |title=Criteria for page selection |include={DPL manual}:section }}