Difference between revisions of "Template:Glossary term/doc"

From blackwiki
Jump to navigation Jump to search
imported>Mathglot
(Creating, to accompany Template:Glossary term.)
 
imported>Mathglot
(Tidy examples.)
Line 7: Line 7:
 
This template takes up to two optional parameters which will alter the expression used to link to the Glossary.  
 
This template takes up to two optional parameters which will alter the expression used to link to the Glossary.  
  
*<nowiki>{{Glossary term |alternative term link |different display text, if desired}}</nowiki>
+
* <code><nowiki>{{Glossary term |alternative term link |different display text, if desired}}</nowiki></code>
  
 
==Examples==
 
==Examples==
<nowiki>{{Glossary term |1=Hatnote |2=hat note}}</nowiki>
+
* <code><nowiki>{{Glossary term |1=Hatnote |2=hat note}}</nowiki></code>
 
 
 
 
* <nowiki>AAA {{User:Mathglot/sandbox/Templates/Glossary term |1=Hatnote |2=hat note}}
 
 
 
* <nowiki>BBB {{User:Mathglot/sandbox/Templates/Glossary term |1=Three-revert rule |2=three revert rule}}</nowiki>
 
 
 
* CCC <nowiki>{{Glossary term|1=Wikipedia:Administrators' noticeboard/Incidents|2=ANI}}</nowiki>
 
  
 
produces
 
produces
Line 23: Line 16:
 
{{-}}
 
{{-}}
  
{{User:Mathglot/sandbox/Templates/Glossary term |1=Hatnote |2=hat note}}
+
* <code><nowiki>{{Glossary term |1=Three-revert rule |2=three revert rule}}</nowiki></code>
  
 +
produces
 
{{User:Mathglot/sandbox/Templates/Glossary term |1=Three-revert rule |2=three revert rule}}
 
{{User:Mathglot/sandbox/Templates/Glossary term |1=Three-revert rule |2=three revert rule}}
 +
{{-}}
  
{{User:Mathglot/sandbox/Templates/Glossary term|1=Wikipedia:Administrators' noticeboard/Incidents|2=ANI}}
+
* <code><nowiki>{{Glossary term |Watchlist |Watch list}}</nowiki></code>
  
{{User:Mathglot/sandbox/Templates/Glossary term|1=ANI |2=Wikipedia:Administrators' noticeboard/Incidents}}
+
produces
 +
{{User:Mathglot/sandbox/Templates/Glossary term |Watchlist |Watch list}}
  
 
{{-}}
 
{{-}}

Revision as of 02:51, 29 July 2019

Usage

The default behavior of this template is to present a string "The Wikipedia Glossary has an entry for" with a link to the entry at Wikipedia:Glossary with the same name as the Wikipedia page on which it appears.

This template takes up to two optional parameters which will alter the expression used to link to the Glossary.

  • {{Glossary term |alternative term link |different display text, if desired}}

Examples

  • {{Glossary term |1=Hatnote |2=hat note}}

produces User:Mathglot/sandbox/Templates/Glossary term

  • {{Glossary term |1=Three-revert rule |2=three revert rule}}

produces User:Mathglot/sandbox/Templates/Glossary term

  • {{Glossary term |Watchlist |Watch list}}

produces User:Mathglot/sandbox/Templates/Glossary term

Limitations

[] - square brackets

  • You cannot use square brackets ("[" and "]") in the first parameter.

To resolve this use "&#91;" and "&#93;" instead:

TemplateData

This is the TemplateData documentation for this template used by VisualEditor and other tools; see the monthly parameter usage report for this template.

TemplateData for Glossary term

Creates a small box with a links to an entry at Wikipedia:Glossary.

Template parameters

ParameterDescriptionTypeStatus
Entry name1

The name of the expression in the Glossary. The article's page name is used as a default. Square brackets <tt>&#91;</tt> and <tt>&#93;</tt> need to be coded as <tt>&amp;#91;</tt> and <tt>&amp;#93;</tt> instead.

Stringoptional
Displayed name2

Optional displayed link text.

Stringoptional

See also