More actions
Created page with "<noinclude>{{Documentation subpage}}</noinclude> {{Source|Minecraft}} {{shortcut|tl|t}} This template is used to easily link to a template, while displaying the template brackets. == Usage == {{tcode|tl|template name|subst{{=}}<var>yes/no</var>|code{{=}}<var>yes/no</var>}} ''template name'' can be any page, using the same conventions as transclusion. Basically the "Template:" prefix is optional, and a colon is required to link the main space. Parameters can also be ad..." |
mNo edit summary |
||
Line 1: | Line 1: | ||
{{Documentation header}} | |||
{{shortcut|tl|t}} | {{shortcut|tl|t}} | ||
This template is used to easily link to a template, while displaying the template brackets. | This template is used to easily link to a template, while displaying the template brackets. | ||
Line 9: | Line 8: | ||
''template name'' can be any page, using the same conventions as transclusion. Basically the "Template:" prefix is optional, and a colon is required to link the main space. | ''template name'' can be any page, using the same conventions as transclusion. Basically the "Template:" prefix is optional, and a colon is required to link the main space. | ||
Parameters can also be added, to a maximum of 8. Note that <code>=</code>'s must be escaped using {{ | Parameters can also be added, to a maximum of 8. Note that <code>=</code>'s must be escaped using <code><nowiki>{{=}}</nowiki></code>. | ||
The {{para|subst}} parameter will determine whether the template link will display as a substed template or not. If the subst parameter is set, it will display the word "subst:" in front of the template link. | The {{para|subst}} parameter will determine whether the template link will display as a substed template or not. If the subst parameter is set, it will display the word "subst:" in front of the template link. | ||
Line 18: | Line 17: | ||
* {{tcode|tl|OS}} → {{tl|OS}} | * {{tcode|tl|OS}} → {{tl|OS}} | ||
* {{tcode|tl|Template:Welcome|subst{{=}}yes}} → {{tl|Template:Welcome|subst=yes}} | * {{tcode|tl|Template:Welcome|subst{{=}}yes}} → {{tl|Template:Welcome|subst=yes}} | ||
* {{tcode|tl|: | * {{tcode|tl|:Spawner/BE}} → {{tl|:Spawner/BE}} | ||
* {{tcode|tl|move|Page to move to|Optional reason}} → {{tl|move|Page to move to|Optional reason}} | * {{tcode|tl|move|Page to move to|Optional reason}} → {{tl|move|Page to move to|Optional reason}} | ||
* {{tcode|tl|uw-vandalism|Minecraft|subst{{=}}1}} → {{tl|Uw-vandalism|Minecraft|subst=1}} | * {{tcode|tl|uw-vandalism|Minecraft|subst{{=}}1}} → {{tl|Uw-vandalism|Minecraft|subst=1}} | ||
Line 29: | Line 28: | ||
<!-- Template categories/interwiki here --> | <!-- Template categories/interwiki here --> | ||
[[Category:Link templates]] | [[Category:Link templates]] | ||
</includeonly> | </includeonly> |
Latest revision as of 19:49, 16 June 2025
[purge]
This is the documentation page. It should be transcluded into Template:Template link. See Template:Documentation for more information.This template is used to easily link to a template, while displaying the template brackets.
Usage
{{tl|template name|subst=yes/no|code=yes/no}}
template name can be any page, using the same conventions as transclusion. Basically the "Template:" prefix is optional, and a colon is required to link the main space.
Parameters can also be added, to a maximum of 8. Note that =
's must be escaped using {{=}}
.
The |subst=
parameter will determine whether the template link will display as a substed template or not. If the subst parameter is set, it will display the word "subst:" in front of the template link.
Set |code=
to no to disable code formatting.
Examples
{{tl|OS}}
→{{OS}}
{{tl|Template:Welcome|subst=yes}}
→{{subst:Welcome}}
{{tl|:Spawner/BE}}
→{{ :Spawner/BE}}
{{tl|move|Page to move to|Optional reason}}
→{{move|Page to move to|Optional reason}}
{{tl|uw-vandalism|Minecraft|subst=1}}
→{{subst:Uw-vandalism|Minecraft}}
See also
{{TemplateCode}}
{{parameter}}