More actions
m Changed protection level of Template:1x: Enable access by template editors ([Edit=Allow only template editors and admins] (indefinite) [Move=Allow only template editors and admins] (indefinite)) |
m 1 revision imported |
(No difference)
|
Latest revision as of 12:20, 28 July 2024
{{{1}}}
Usage
Echo the first argument to the template through the rendering engine.
This is occasionally useful as a metatemplate. For example:
- To break up certain constructs that otherwise have special meaning in wikitext.
{{1x|~~}}{{1x|~~}}
→ ~~~~
- To strip white space from a template parameter.
a{{{1| x }}}b
→ a x ba{{1x|1= {{{1| x }}} }}b
→ axb
- To conditionally hide or show some content by choosing which template takes a parameter.
{{ {{#if: {{{x}}} | 2x | 1x }} | hello }}
→ hello hello{{ {{#if: {{{x}}} | void | 1x }} | hello }}
→ Template:Void