Template:!)/doc: Difference between revisions

From Saintapedia
Jump to navigation Jump to search
>Rusty.perrin
m (Replace spaces with non-break spaces)
 
>ExE Boss
Line 1: Line 1:
{{Documentation subpage}}
{{Documentation subpage}}
<!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE -->
<!-- PLEASE ADD CATEGORIES AT THE BOTTOM OF THIS PAGE -->
{{tc}}
{{High-use|200000+}}
== Usage ==
{{Auxiliary template common notice|entity=#124;&amp;#125}}


The {{tlx|(!}}, {{tlx|!}}, and {{tlx|!)}} templates produce table codes for {{xt|<nowiki>{|</nowiki>}} (start of wiki table), {{xt|<nowiki>|</nowiki>}} (new cell in wikitable), and {{xt|<nowiki>|}</nowiki>}} (end of wikitable) sequences, so that wikitables can be built inside templates without vertical bar (&nbsp;{{xt|<nowiki>|</nowiki>}}&nbsp;) characters interfering with template [[parser functions]].
<includeonly>{{Sandbox other||
 
[[Category:Templates with partial table wikitext]]
There is also a {{tlx|!-}} template to produce {{xt|<nowiki>|-</nowiki>}} code for a new row in a table, but you can also use {{tlx|!}}- to achieve the same thing.
[[Category:Character-substitution templates]]
 
}}</includeonly>
==Example==
The following code within a template would result in table coding where the vertical bar ({{!}}) characters don't interfere with any parser functions that the table falls within.
{| class=wikitable
! What you put in the template !! Works like you would normally expect this code to work !! Resulting table
|- valign=top
|
{{pre|<nowiki>
{{(!}} class=wikitable
! Column header 1 !! Column header 2
{{!}}-
{{!}} Table content
{{!}} Table content
{{!)}}</nowiki>}}
|
{{pre|<nowiki>
{| class=wikitable
! Column header 1 !! Column header 2
|-
| Table content
| Table content
|}</nowiki>}}
|
{| class=wikitable
! Column header 1 !! Column header 2
|-
| Table content
| Table content
|}
|}
<includeonly>
[[Category:Powerpedia formatting and function templates]]
</includeonly>

Revision as of 08:49, 2 April 2021

Usage

This template can be used in place of a literal "|}" when the latter would be interpreted as a syntactic marker.

For example, {{!)}} gives "|}".
Alternatively, the HTML entity "&#124;&#125;" can be used to show a "|&#125;".

See also