Template:Template link with subst and parameters/doc: Difference between revisions

Content deleted Content added
Amalthea (talk | contribs)
update doc
add template
 
(15 intermediate revisions by 14 users not shown)
Line 1:
{{Documentation subpage}}
{{Tlx|{{PAGENAME}}Tlsp}} is used in template lists. Unlike
 
{{Tlx|{{PAGENAME}}}} is used in template lists. Unlike
{{Tlx|Tlp}} it includes "[[WP:SUBST|subst]]". Unlike
{{Tlx|Tls}} it allows to specify a parameter. These
features are hints how to use the specified template.
 
=== Usage ===
 
;Up to five placeholders for parameters of the specified template name:
:{{Tlx|{{PAGENAME}}Tlsp|template name}}
:{{Tlx|{{PAGENAME}}Tlsp|template name|param}}
:{{Tlx|{{PAGENAME}}Tlsp|template name|1|2|3|4|5}}
:{{Tlx|{{PAGENAME}}Tlsp|template name|3=2=param==value}} Note: start from 2 because the "name" is parameter 1. Or...
:{{Tlx|Tlsp|template name|param=value}}
;For templates supporting [[Help:Substitution#Optional_substitution|optional substitution]] just add <ttcode>subst=subst:</ttcode>
:{{Tlx|{{PAGENAME}}Tlsp|template name|1<tt>&#124;</tt>|2<tt>&#124;</tt>|3|46=subst=subst:}}
 
=== Example ===
<!-- some magic here where Tlx talks about Tlsp,
Tlx has the same limitations wrt parameters -->
Line 28 ⟶ 27:
| {{Tlx|tlsp|template|1st|2nd|3rd|4th|5th}}
| {{tlsp|template|1st|2nd|3rd|4th|5th}}
|-
| {{Tlx|tlsp|template|3=2=param=value}}
| {{Pp-tlsp|template|small2=param=yesvalue}}
|-
| {{Tlx|tlsp|template|param&amp;#61;value}}
| {{tlsp|template|param&#61;value}}
|-
| {{Tlx|tlsp|template|1<tt>&#124;</tt>|2<tt>&#124;</tt>|3&amp;#124;okay}}
| {{tlsp|template|1|2|3&#124;okay}}
|-
Line 44 ⟶ 46:
''For similar examples see [[Template talk:Tlx#Example|Tlx]].''
 
=== Comparison ===
{|
| '''Code'''
Line 61 ⟶ 63:
| {{tlsp|x3|1st|2nd|3rd|4th|5th}}
|-
| {{Tlx|tlu|template:x3|1st<tt>&#124;</tt>|2nd<tt>&#124;</tt>|3rd}} &#160;
| {{tlu|template:x3|1st|2nd|3rd}}
|-
| {{Tlx|tlx|x3|1st<tt>&#124;</tt>|2nd<tt>&#124;</tt>|3rd}}
| {{tlx|x3|1st|2nd|3rd}}
|}{{-}}
 
=== See also ===
* {{Lts|{{PAGENAME}}Tlsp}} up to fourfive parameters
 
* {{Lts|{{PAGENAME}}}} up to four parameters
* {{Lts|Tl}} no parameter and no subst
* {{Lts|Tlp}} Tl + parameter
Line 77 ⟶ 78:
* {{Lts|Tlx}} like Tlsp without subst
 
{{Template-linking templates}}
<includeonly>
[[Category:Internal link templates|Tlsp]]
 
<includeonly>{{Sandbox other||
[[ko:틀:Tlsp]]
[[Category:Internal template-link templates|Tlsp]]
[[uk:Шаблон:Tlsp]]
}}</includeonly>
{{Pp-template|small=yes}}
</includeonly>