Difference between revisions of "Template:Country2iso3"
Jump to navigation
Jump to search
Template documentation
imported>Guarapiranga m (error) |
imported>Guarapiranga m (missing word) |
||
Line 1: | Line 1: | ||
<includeonly>{{#lst:ISO 3166-1 alpha-3|{{{1}}}}}</includeonly><noinclude> | <includeonly>{{#lst:ISO 3166-1 alpha-3|{{{1}}}}}</includeonly><noinclude> | ||
{{Documentation|content= | {{Documentation|content= | ||
− | This template does the same as {{tl|ISO 3166 code-3}}, however, rather than being [[Lua (programming language)|Lua]]-based like {{tl|ISO 3166 code-3}}, it transcludes the ISO codes [[ISO 3166-1 alpha-3]] based on the provided country name. This is particularly useful when [[Help:Substitution|subst'ing]] ISO codes, as [[Lua (programming language)|Lua]] modules need to be [[Help:Substitution|subst'd]] twice, and {{tl|ISO 3166 code-3}} often times out on long lists of countries. | + | This template does the same as {{tl|ISO 3166 code-3}}, however, rather than being [[Lua (programming language)|Lua]]-based like {{tl|ISO 3166 code-3}}, it transcludes the ISO codes from [[ISO 3166-1 alpha-3]] based on the provided country name. This is particularly useful when [[Help:Substitution|subst'ing]] ISO codes, as [[Lua (programming language)|Lua]] modules need to be [[Help:Substitution|subst'd]] twice, and {{tl|ISO 3166 code-3}} often times out on long lists of countries. |
=== Usage === | === Usage === |
Latest revision as of 03:30, 31 October 2019

This template does the same as {{ISO 3166 code-3}}, however, rather than being Lua-based like {{ISO 3166 code-3}}, it transcludes the ISO codes from ISO 3166-1 alpha-3 based on the provided country name. This is particularly useful when subst'ing ISO codes, as Lua modules need to be subst'd twice, and {{ISO 3166 code-3}} often times out on long lists of countries.
Usage
{{Country2iso3 | country name}}
Example
{{Country2iso3 | China}}
yields {{#lst:ISO 3166-1 alpha-3| China}}
Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages. Subpages of this template. |