Template:Country data Eswatini/doc: Difference between revisions

From Zoophilia Wiki
Jump to navigationJump to search
meta>Wiz9999
Restoration of this page to pre-deletion status after the template breaking edits & deletions by Andrwsc.
 
Ookami (talk | contribs)
m 4 revisions imported
 
(3 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{Documentation subpage}}
{{Documentation subpage}}
<includeonly>


Rather than redirecting {{tl|Country data Swaziland}} to {{tl|Country data Eswatini}}, the former template transcludes the latter and passes through all parameters. The linked article will always be "Eswatini", but the displayed name is either "Swaziland" or "Eswatini" based on which of the two templates is used, even in templates that usually have a fixed default display name (such as {{tl|flagcountry}} and {{tl|fb}}). This allows for "Swaziland" to be used in historical contexts without having to also set {{para|name}}.
Rather than redirecting {{tl|Country data Swaziland}} to {{tl|Country data Eswatini}}, the former template transcludes the latter and passes through all parameters. The linked article will always be "Eswatini", but the displayed name is either "Swaziland" or "Eswatini" based on which of the two templates is used, even in templates that usually have a fixed default display name (such as {{tl|flagcountry}} and {{tl|fb}}). This allows for "Swaziland" to be used in historical contexts without having to also set {{para|name}}.
Line 9: Line 8:
! Template !! <code>Eswatini</code> output !! <code>Swaziland</code> output
! Template !! <code>Eswatini</code> output !! <code>Swaziland</code> output
|-
|-
| {{tlx|flag|SWA}} || {{flag|Eswatini}} || {{flag|Swaziland}}
| {{tlx|flag|SWZ}} || {{flag|Eswatini}} || {{flag|Swaziland}}
|-
|-
| {{tlx|flagcountry|SWA}} || {{flagcountry|Eswatini}} || {{flagcountry|Swaziland}}
| {{tlx|flagcountry|SWZ}} || {{flagcountry|Eswatini}} || {{flagcountry|Swaziland}}
|-
|-
| {{tlx|flagicon|SWA}} || {{flagicon|Eswatini}} || {{flagicon|Swaziland}}
| {{tlx|flagicon|SWZ}} || {{flagicon|Eswatini}} || {{flagicon|Swaziland}}
|-
|-
| {{tlx|fb|SWA}} || {{fb|Eswatini}} || {{fb|Swaziland}}
| {{tlx|fb|SWZ}} || {{fb|Eswatini}} || {{fb|Swaziland}}
|}
|}


<includeonly>{{Sandbox other||
{{#ifeq:{{PAGENAME}}|Country data Eswatini|
{{#ifeq:{{PAGENAME}}|Country data Eswatini|
[[Category:Country data templates of countries|Eswatini]]
[[Category:Country data templates of countries|Eswatini]]
[[Category:Country data templates of Eswatini| ]]
[[Category:Country data templates of Eswatini| ]]
}}
}}
</includeonly>
 
}}</includeonly>

Latest revision as of 02:29, 3 September 2020

Rather than redirecting {{Country data Swaziland}} to {{Country data Eswatini}}, the former template transcludes the latter and passes through all parameters. The linked article will always be "Eswatini", but the displayed name is either "Swaziland" or "Eswatini" based on which of the two templates is used, even in templates that usually have a fixed default display name (such as {{flagcountry}} and {{fb}}). This allows for "Swaziland" to be used in historical contexts without having to also set |name=.

Examples

Template Eswatini output Swaziland output
{{flag|SWZ}}  Eswatini  Swaziland
{{flagcountry|SWZ}}  Eswatini  Swaziland
{{flagicon|SWZ}} Eswatini Eswatini
{{fb|SWZ}}  Eswatini  Swaziland