Template:Tlx: Difference between revisions

From PZwiki
m (added category to template. Transcluding from documentation not adding it to category??)
(use documentation/sandbox)
Line 1: Line 1:
<includeonly><code><nowiki>{{</nowiki>{{#if:{{{subst|}}}|[[Help:Substitution|subst]]:}}[[{{{LANG|}}}{{{SISTER|}}}{{ns:Template}}:{{{1|}}}|{{{1|}}}]]<!--
<noinclude>
-->{{#if:{{{2|}}}|
{{Documentation/sandbox|doc =
&#124;{{{2}}}
'''Template link expanded''', shortened to {{tlx|tlx}}, is used to provide stylized formatting to template displays withoutactually using the template itself. The code generated will be displayed inline.
}}<!--
==Usage==
-->{{#if:{{{3|}}}|
===Parameters===
&#124;{{{3}}}
;<code>1</code> <sup>(required)</sup>
}}<!--
:The name of the template to be displayed.
-->{{#if:{{{4|}}}|
;<code>2</code> - <code>12</code>
&#124;{{{4}}}
:Parameters to be displayed within the template.
}}<!--
;<code>subst</code>
-->{{#if:{{{5|}}}|
:If not empty, will display a link to the template with the <code>subst:</code> prefix.
&#124;{{{5}}}
;<code>SISTER</code>
}}<!--
:Interwiki prefix for the template. e.g. <code>mw:</code>.
-->{{#if:{{{6|}}}|
&#124;{{{6}}}
}}<!--
-->{{#if:{{{7|}}}|
&#124;{{{7}}}
}}<!--
-->{{#if:{{{8|}}}|
&#124;{{{8}}}
}}<!--
-->{{#if:{{{9|}}}|
&#124;{{{9}}}
}}<!--
-->{{#if:{{{10|}}}|
&#124;{{{10}}}
}}<!--
-->{{#if:{{{11|}}}|
&#124;{{{11}}}
}}<!--
-->{{#if:{{{12|}}}|
&#124;''...''
}}<nowiki>}}</nowiki></code></includeonly><noinclude>


{{documentation}}
==Examples==
[[Category:Metatemplates]]
*<code><nowiki>{{tlx|tlx|About}}</nowiki></code> -> {{tlx|About}}
</noinclude>
*<code><nowiki>{{tlx|tlx|About|Use1}}</nowiki></code> -> {{tlx|About|Use1}}
*<code><nowiki>{{tlx|tlx|About|subst=1}}</nowiki></code> -> {{tlx|About|subst=1}}
*<code><nowiki>{{tlx|tlx|About|SISTER=mw:}}</nowiki></code> -> {{tlx|About|SISTER=mw:}}
 
{{Translation guide}}
 
==See also==
*{{ll|Template:Localized link}}
*[[mw:Template:Tlx]]
}}
{{ll|Category:Metatemplates}}
</noinclude><includeonly><code><nowiki>{{</nowiki>{{#if:{{{subst|}}}|[[mw:Help:Substitution|subst]]:}}[[{{{SISTER|}}}{{ns:Template}}:{{{1|[[Category:Incorrect template usage]]}}}|{{{1|}}}]]<!--
-->{{#if:{{{2|}}}|{{!}}{{{2}}}
}}{{#if:{{{3|}}}|{{!}}{{{3}}}
}}{{#if:{{{4|}}}|{{!}}{{{4}}}
}}{{#if:{{{5|}}}|{{!}}{{{5}}}
}}{{#if:{{{6|}}}|{{!}}{{{6}}}
}}{{#if:{{{7|}}}|{{!}}{{{7}}}
}}{{#if:{{{8|}}}|{{!}}{{{8}}}
}}{{#if:{{{9|}}}|{{!}}{{{9}}}
}}{{#if:{{{10|}}}|{{!}}{{{10}}}
}}{{#if:{{{11|}}}|{{!}}{{{11}}}
}}{{#if:{{{12|}}}|{{!}}''...''
}}<nowiki>}}</nowiki></code></includeonly>

Revision as of 15:26, 29 December 2023

Notebook.pngTemplate Documentation

Template link expanded, shortened to {{tlx}}, is used to provide stylized formatting to template displays withoutactually using the template itself. The code generated will be displayed inline.

Usage

Parameters

1 (required)
The name of the template to be displayed.
2 - 12
Parameters to be displayed within the template.
subst
If not empty, will display a link to the template with the subst: prefix.
SISTER
Interwiki prefix for the template. e.g. mw:.

Examples

  • {{tlx|tlx|About}} -> {{About}}
  • {{tlx|tlx|About|Use1}} -> {{About|Use1}}
  • {{tlx|tlx|About|subst=1}} -> {{subst:About}}
  • {{tlx|tlx|About|SISTER=mw:}} -> {{About}}

How to translate

This template doesn't need to/shouldn't be translated, but you can translate the documentation of this template with the following steps:

  1. Create a subpage of this template with the language code of the language you want to translate to.
  2. Copy the code wrapped in the <noinclude> tag in this template into the page you created.
    {{Translation guide}} template should be removed from the translated documentation.
  3. Translate the page according to the translation requirements of normal pages.

See also

Editors can experiment in this template's sandbox.