User:Ris/drafts/templates/Template:Wikipedia/doc

From Gentoo Wiki
Jump to:navigation Jump to:search
Note
This page is a template. It contains some standardized, often used text, which can be transcluded inside other pages. As this template is widely used in our wiki, it may be protected in which case only staff members can change it. Use the discussion page to propose enhancements or fixes, or to voice your opinion.

Template to make linking to Wikipedia articles easier, and to add an icon to the links.

Parameters

Parameter name Required? Default value Description
Anonymous parameter 1 Yes (n/a) Wikipedia page name
Anonymous parameter 2 No (n/a) Link name to display

Usage

{{Wikipedia|Wikipedia page name}}
{{Wikipedia|Wikipedia page name|Link name to display}}

See the template's testcases:


Correct

One anonymous parameter: Wikipedia page name
Wiki code
{{User:Ris/drafts/templates/Template:Wikipedia|Gentoo}}
Main version
Sandbox version


Two anonymous parameters: Wikipedia page name and link name to display
Wiki code
{{User:Ris/drafts/templates/Template:Wikipedia|Gentoo|Gentoo Linux}}
Main version
Sandbox version


Incorrect

No parameter (error message)
Wiki code
{{User:Ris/drafts/templates/Template:Wikipedia}}
Main version
{{Wikipedia template error}}
Parameter Anonymous parameter not defined. For correct usage see Wikipedia template's documentation on the Anonymous parameter parameter.
Sandbox version


See also

  • [[]]