Template:=/doc: Difference between revisions

From the Croc Wiki, the Croc encyclopedia
Jump to navigationJump to search
Content added Content deleted
No edit summary
m (99 revisions imported: All these templates have originated from Wikipedia. Credits go directly to them.)
 
(6 intermediate revisions by 5 users not shown)
Line 1: Line 1:
{{mbox|type=notice|text=This template will soon be deprecated, as the {{tl|=}} will soon be a [[Help:Magic words|Magic word]]. See reasons and status at [[phab:T91154]].}}
{{mbox|type=notice|text=This template will soon be deprecated, as the {{tl|{{=}}}} will soon be a [[Help:Magic words|Magic word]]. See reasons and status at [[phab:T91154]].}}
{{Documentation subpage}}
{{Documentation subpage}}
{{High-risk|386,000+}}
{{High-risk|386,000+}}
Line 5: Line 5:


== Usage ==
== Usage ==
This template allows "=" to be used in unnamed template parameters. It inserts the one-character [[equals-sign]] ("=") into the text. However, in [[wp:CS1]] cite titles, the [[Unicode]] form "=" could be used instead, where a literal "=" is not wanted during formatting of a title.
This template allows "=" to be used in unnamed template parameters. It inserts the [[equals-sign]] ("=") into the text. Alternatively, the [[HTML]] entity "=" can be used if there is no need for it to be interpreted as wikimarkup, such as when the literal equals-sign is to be displayed to the user.


== Examples ==
== Examples ==
Line 12: Line 12:
You can also use named parameters to bypass the restriction:
You can also use named parameters to bypass the restriction:
* <code><nowiki>{{Font color|black|yellow|3= 2 + 2 = 4}}</nowiki></code> produces: {{Font color|black|yellow|3= 2 + 2 = 4}}
* <code><nowiki>{{Font color|black|yellow|3= 2 + 2 = 4}}</nowiki></code> produces: {{Font color|black|yellow|3= 2 + 2 = 4}}

Unlike &amp;#61;, the template only delays the interpretation of the symbol as code:
<syntaxhighlight lang="html">
{{concat|<div class{{=}}"hatnote">This should be italicised.</div>}}
{{concat|<div class&#61;"hatnote">This will not be italicised.</div>}}
</syntaxhighlight>
produces:
{{concat|<div class{{=}}"hatnote">This should be italicised.</div>}}
{{concat|<div class&#61;"hatnote">This will not be italicised.</div>}}


== TemplateData ==
== TemplateData ==
Line 24: Line 33:


== See also ==
== See also ==
{{Escape template list}}
* [[Template:((]] which produces: {{code|{{((}}}}
* [[Template:))]] which produces: {{code|{{))}}}}
* <nowiki>{{!}}</nowiki> which produces: {{code|{{!}}}} – this is a Wikimedia [[mw:Help:Magic words#Other|"magic word" added in MediaWiki 1.24]]
* {{tl|ifequal}}
* [[mw:Help:Magic words]]
* [[mw:Help:Magic words]]



Latest revision as of 17:48, January 24, 2022

Usage

This template allows "=" to be used in unnamed template parameters. It inserts the equals-sign ("=") into the text. Alternatively, the HTML entity "&#61;" can be used if there is no need for it to be interpreted as wikimarkup, such as when the literal equals-sign is to be displayed to the user.

Examples

You can also use named parameters to bypass the restriction:

Unlike &#61;, the template only delays the interpretation of the symbol as code:

{{concat|<div class{{=}}"hatnote">This should be italicised.</div>}}
{{concat|<div class&#61;"hatnote">This will not be italicised.</div>}}

produces: Template:Concat Template:Concat

TemplateData

This is the TemplateData for this template used by TemplateWizard, VisualEditor and other tools. Click here to see a monthly parameter usage report for this template based on this TemplateData.

TemplateData for =

A template to allow = to be used in template parameters

Template parameters

This template has custom formatting.

ParameterDescriptionTypeStatus
No parameters specified

See also

Template:Escape template list