Template:Substitution/doc: Difference between revisions

From Zoophilia Wiki
Jump to navigationJump to search
meta>Wbm1058
meta>Geekdiva
→‎Example: Clarified the note that you should not include a period to say to not include any ending punctuation because the template adds a period/full stop. Added more varied examples with sub-subheads.
Line 7: Line 7:


===Parameters===
===Parameters===
The first parameter inserts a word between "should" and "be", e.g. "always", "never" etc. To have no word instead, insert a space.
The first parameter inserts a word that you choose in between "should" and "be", such as "always" or "never." To have no word between "should" and "be", insert a space.


The second parameter is optional. It adds text to the end of the sentence.
The second parameter is optional. It adds text to the end of the sentence. Note that you should '''''not''''' include punctuation at the end. The template will always include a full stop (a period) at the end for you.


==Example==
==Examples==
=== With a word and no additional text ===
<code><nowiki>{{Substitution|not}}</nowiki></code>
 
produces:
 
{{Substitution|not}}
 
=== With a word and additional text ===
<code><nowiki>{{Substitution|only|if temperatures fall and it starts to snow}}</nowiki></code>
<code><nowiki>{{Substitution|only|if temperatures fall and it starts to snow}}</nowiki></code>


Line 18: Line 26:
{{Substitution|only|if temperatures fall and it starts to snow}}
{{Substitution|only|if temperatures fall and it starts to snow}}


(Note that a full stop (a period) should '''''not''''' be included at the end.  The template will include it for you.)
 
=== With no word and additional text ===
Note the space in the first parameter.
 
<code><nowiki>{{Substitution| |if you wish to ensure your emoji's image remains the same even if its template's image is changed}}</nowiki></code>
 
produces:
 
{{Substitution| |if you wish to ensure your [[wp:emojis|emoji image]] remains the same even if its template image is changed}}


==See also==
==See also==
* {{tlx|Nosubst}}
* {{tl|Nosubst}}
* {{tlx|Subst only}}
* {{tl|Subst only}}
* {{tlx|Transclusionless}}
* {{tl|Transclusionless}}


<includeonly>
<includeonly>
[[Category:Template namespace templates]]
[[Category:Template namespace templates]]
</includeonly>
</includeonly>

Revision as of 06:27, 8 February 2016

Usage

Add this message box to a template's documentation to briefly explain the rules of substitution for the template.

Parameters

The first parameter inserts a word that you choose in between "should" and "be", such as "always" or "never." To have no word between "should" and "be", insert a space.

The second parameter is optional. It adds text to the end of the sentence. Note that you should not include punctuation at the end. The template will always include a full stop (a period) at the end for you.

Examples

With a word and no additional text

{{Substitution|not}}

produces:

With a word and additional text

{{Substitution|only|if temperatures fall and it starts to snow}}

produces:


With no word and additional text

Note the space in the first parameter.

{{Substitution| |if you wish to ensure your emoji's image remains the same even if its template's image is changed}}

produces:

See also