Jump to content
Toggle menu
  • 8 articles
  • 75 files
  • 7 users
  • 37.8K edits
Neodyland Wiki
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Template:Country/doc: Difference between revisions

Template page
+1 example
remove North Macedonian example, since New Zealand one shows same functionality with a different script (= slightly more interesting)
Line 36: Line 36:
* “Estonia” in Estonian: {{tlc|Country|EE|3=lang=et}} → {{Country|EE|lang=et}}
* “Estonia” in Estonian: {{tlc|Country|EE|3=lang=et}} → {{Country|EE|lang=et}}
* “Estonia” in German: {{tlc|Country|EE|3=lang=de}} → {{Country|EE|lang=de}}
* “Estonia” in German: {{tlc|Country|EE|3=lang=de}} → {{Country|EE|lang=de}}
* “North Macedonia” in Italian: {{tlc|Country|MK|3=lang=it}} → {{Country|MK|lang=it}}
* "New Zealand" in Russian: {{tlc|Country|NZ|3=lang=ru}} → {{Country|NZ|lang=ru}}
* "New Zealand" in Russian: {{tlc|Country|NZ|3=lang=ru}} → {{Country|NZ|lang=ru}}
* "Ukraine" in Ukrainian with no wikilink: {{tlc|Country|UA|3=lang=uk|4=nolink=1}} → {{Country|UA|lang=uk|nolink=1}}
* "Ukraine" in Ukrainian with no wikilink: {{tlc|Country|UA|3=lang=uk|4=nolink=1}} → {{Country|UA|lang=uk|nolink=1}}

Revision as of 12:52, 24 February 2020

Given the ISO code for a country, it checks if the English language name of the country matches a template name (e.g., EE → {{Estonia}}). If such a template exists, it calls that template; if not, it returns the English name. The individual country templates provide localization of country names, and link the localized name to the Wikipedia entry in the relevant language (e.g., {{Estonia}} produces: Template:Estonia).

Usage

{{Country |1= }}

Template parameters

ParameterDescriptionDefaultStatus
1ISO code for country (e.g., EE = Estonia — for a list see en:ISO 3166-1 alpha-2)emptyrequired
langlanguage code (must be entirely lowercase)emptyoptional
nolinkset to suppress hyperlinkemptyoptional

Additional information

The template is intended to be used in the following namespaces: all namespaces

The template is intended to be used by the following user groups: all users

See also

{{CountryName}}, which provides just the country name without linking it

Localization

This template is not intended to be localized.

Examples

  • “Estonia” in user's selected language: {{Country|EE}} → Estonia
  • “Estonia” in Estonian: {{Country|EE|lang=et}} → Estonia
  • “Estonia” in German: {{Country|EE|lang=de}} → Estonia
  • "New Zealand" in Russian: {{Country|NZ|lang=ru}} → New Zealand
  • "Ukraine" in Ukrainian with no wikilink: {{Country|UA|lang=uk|nolink=1}} → Ukraine
Cookies help us deliver our services. By using our services, you agree to our use of cookies.