Template:W: Difference between revisions
Jump to navigation
Jump to search
Documentation
mNo edit summary |
mNo edit summary |
||
(2 intermediate revisions by the same user not shown) | |||
Line 7: | Line 7: | ||
===Syntax=== | ===Syntax=== | ||
{{tl|W| | {{tl|W|1{{=}}<''Wikipedia article''>|2{{=}}<''displayed text''>|lang{{=}}<''2-digit language code''>}} | ||
: | :or | ||
{{tl|w|<''Wikipedia article''>|<''displayed text''>|lang{{=}}<''2-digit language code''>}} | |||
where | |||
*{{para|1}} the {{w|Wikipedia:Article titles|Wikipedia article title}}. It is mandatory; | |||
*{{para|2}} optional text to be displayed in the link. If not specified, the Wikipedia title will be used; | |||
*{{para|lang}} language of the Wikipedia article. It's the first two digits of the link (for example, '''de''' in de.wikipedia.org); when not specified, the template defaults to English. | |||
Note that hovering the mouse over the <sup>[[File:Wikipedia's W.svg|12px|link=|]]</sup> will display a tooltip box with information about the link and the article's language. | |||
===Examples=== | |||
{{tl|W|counterpoint}} | |||
:produces: | |||
{{W|counterpoint}} | {{W|counterpoint}} | ||
{{tl|W|William Smith (composer)|William Smith}} | {{tl|W|William Smith (composer)|William Smith}} | ||
: | :produces: | ||
{{W|William Smith (composer)|William Smith}} | {{W|William Smith (composer)|William Smith}} | ||
{{tl|W|Franz Xaver Engelhart|lang{{=}}de}} | {{tl|W|Franz Xaver Engelhart|lang{{=}}de}} | ||
: | :produces: | ||
{{W|Franz Xaver Engelhart|lang=de}} | {{W|Franz Xaver Engelhart|lang=de}} | ||
Latest revision as of 00:37, 8 December 2020
This template is used to create an inline link to the corresponding Wikipedia article for that subject.
Syntax
{{W|1=<Wikipedia article>|2=<displayed text>|lang=<2-digit language code>}}
- or
{{w|<Wikipedia article>|<displayed text>|lang=<2-digit language code>}}
where
|1=
the Wikipedia article title. It is mandatory;|2=
optional text to be displayed in the link. If not specified, the Wikipedia title will be used;|lang=
language of the Wikipedia article. It's the first two digits of the link (for example, de in de.wikipedia.org); when not specified, the template defaults to English.
Note that hovering the mouse over the will display a tooltip box with information about the link and the article's language.
Examples
{{W|counterpoint}}
- produces:
{{W|William Smith (composer)|William Smith}}
- produces:
{{W|Franz Xaver Engelhart|lang=de}}
- produces:
Categorization
The page is categorized according to the language of the Wikipedia article: English Wikipedia links, French Wikipedia links etc.