Template:Country showdata: Difference between revisions
From Hattrick
Jump to navigationJump to search
No edit summary |
mNo edit summary |
||
| (25 intermediate revisions by 2 users not shown) | |||
| Line 1: | Line 1: | ||
<includeonly>__NOEDITSECTION__ | <includeonly>__NOEDITSECTION__ | ||
<div style="clear: both; margin: 1em 0 0 0; border: 1px solid #aaa; background-color: #ecfcf4; padding: 1em;"> | |||
<div style="padding-bottom: 3px; border-bottom: 1px solid #aaa; margin-bottom: 1ex;"> | |||
<span style="float: right; margin-left: 5px; background: none !important; padding: 0 !important;">[[{{fullurl:Template:Country showdata|action=edit}} edit]]</span> | |||
<span style="font-weight: bold; font-size: 125%">[[Image:Template-info.png|50px|alt=|link=]] Template documentation</span> | |||
</div> | |||
<tt>Template:{{PAGENAME}}</tt> is an internal data container not intended to be transcluded directly. It is used indirectly by templates such as <tt>[[Template:flag|flag]]</tt>, <tt>[[Template:flagicon|flagicon]]</tt>, and others. | <tt>Template:{{PAGENAME}}</tt> is an internal data container not intended to be transcluded directly. It is used indirectly by templates such as <tt>[[Template:flag|flag]]</tt>, <tt>[[Template:flagicon|flagicon]]</tt>, and others. | ||
__NOTOC__ | |||
[[File:{{{flag alias|Unknown.png}}}|thumb]] | [[File:{{{flag alias|Unknown.png}}}|thumb|Icon]] | ||
{{#if: {{{flag full|}}} |[[File:{{{flag full}}}|thumb|Full size flag of {{{alias}}} (alternative)]]|}} | |||
{{#if: {{{flag logo|}}} |[[File:{{{flag logo}}}|thumb|Country logo]]|}} | |||
===Standard parameters=== | ===Standard parameters=== | ||
<table class="wikitable"> | <table class="wikitable" style="font-size:92%; margin-right:2em;"> | ||
<tr><th>Parameter name</th><th>Value</th><th>Meaning</th> | <tr><th>Parameter name</th><th>Value</th><th>Meaning</th><th>Link</th></tr> | ||
</tr><tr> | <tr><td><tt>name</tt></td> | ||
<td><tt> | <td>{{#if: {{{name|}}} | <tt>{{{name}}}</tt> | <span style="color:red">'''undefined!'''</span> }}</td> | ||
<td>{{#if: {{{ | <td>Main article name </td><td>([[{{{name}}}]])</td></tr> | ||
<td>Main article name ([[{{{ | {{#if: {{{alias|}}} | | ||
</tr> | <tr><td><tt>alias</tt></td><td><tt>{{{alias}}}</tt></td><td>English name</td><td>-</td></tr>}} | ||
<tr> | <tr><td><tt>flag alias</tt></td> | ||
<td><tt>flag alias</tt></td> | |||
<td>{{#if: {{{flag alias|}}} | <tt>{{{flag alias}}}</tt> | <span style="color:red">'''undefined!'''</span> }}</td> | <td>{{#if: {{{flag alias|}}} | <tt>{{{flag alias}}}</tt> | <span style="color:red">'''undefined!'''</span> }}</td> | ||
<td> | <td>Flag icon</td><td>([[:File:{{{flag alias}}}]])</td></tr> | ||
{{#if: {{{flag full|}}} | <tr><td><tt>flag full</tt></td><td><tt>{{{flag full}}}</tt></td><td>Full size flag</td><td>([[:File:{{{flag full}}}]])</td></tr> |}} | |||
{{#if: {{{flag logo|}}} | <tr><td><tt>flag logo</tt></td><td><tt>{{{flag logo}}}</tt><td>"Ball" logo flag</td><td>([[:File:{{{flag logo}}}]])</td></tr> |}}</td> | |||
</table> | |||
====Example usage==== | |||
<table> | |||
<tr><td>* <tt><nowiki>{{flag|</nowiki>{{{templatename|{{{alias}}}}}}<nowiki>}}</nowiki></tt> → </td><td>{{flag|{{{templatename|{{{alias}}}}}}}}</td></tr> | |||
<tr><td>* <tt><nowiki>{{flaglink|</nowiki>{{{templatename|{{{alias}}}}}}<nowiki>}}</nowiki></tt> → </td><td>{{flaglink|{{{templatename|{{{alias}}}}}}}}</td></tr> | |||
<tr><td>* <tt><nowiki>{{flagicon|</nowiki>{{{templatename|{{{alias}}}}}}<nowiki>}}</nowiki></tt> → </td><td>{{flagicon|{{{templatename|{{{alias}}}}}}}}</td></tr> | |||
{{#if: {{{flag full|}}} |<tr><td> * <tt><nowiki>{{flagfull|</nowiki>{{{templatename|{{{alias}}}}}}<nowiki>|showlink}}</nowiki></tt> → </td><td>{{flagfull|{{{templatename|{{{alias}}}}}}|showlink}}</td></tr>|}} | |||
{{#if: {{{flag logo|}}} |<tr><td> * <tt><nowiki>{{flaglogo|</nowiki>{{{templatename|{{{alias}}}}}}<nowiki>|size=x60px}}</nowiki></tt> → </td><td>{{flaglogo|{{{templatename|{{{alias}}}}}}|size=x60px}}</td></tr>|}} | |||
</table> | </table> | ||
{{#if: {{{redir1|}}} | | {{#if: {{{redir1|}}} | | ||
===Redirect | ===Redirect=== | ||
This template can also be used via an '' | This template can also be used via an ''alternative name'' (up to 5 and implemented as a redirect to this template):<!-- | ||
--><table class="wikitable"><!-- | --><table class="wikitable"><!-- | ||
--><tr><th> | --><tr><th>Alternative name</th><th>{{t|flag|''alias''}} output</th><th>{{t|flaglink|''alias''}} output</th></tr> | ||
{{#if: {{{redir1|}}} | <tr><td><tt>{{{redir1}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir1}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir1}}}}}</td><td>{{ | {{#if: {{{redir1|}}} | <tr><td><tt>{{{redir1}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir1}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir1}}}}}</td><td>{{flaglink|{{{redir1}}}}}</td></tr> }}<!-- | ||
-->{{#if: {{{redir2|}}} | <tr><td><tt>{{{redir2}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir2}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir2}}}}}</td><td>{{ | -->{{#if: {{{redir2|}}} | <tr><td><tt>{{{redir2}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir2}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir2}}}}}</td><td>{{flaglink|{{{redir2}}}}}</td></tr> }}<!-- | ||
-->{{#if: {{{redir3|}}} | <tr><td><tt>{{{redir3}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir3}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir3}}}}}</td><td>{{ | -->{{#if: {{{redir3|}}} | <tr><td><tt>{{{redir3}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir3}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir3}}}}}</td><td>{{flaglink|{{{redir3}}}}}</td></tr> }}<!-- | ||
-->{{#if: {{{redir4|}}} | <tr><td><tt>{{{redir4}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir4}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir4}}}}}</td><td>{{ | -->{{#if: {{{redir4|}}} | <tr><td><tt>{{{redir4}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir4}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir4}}}}}</td><td>{{flaglink|{{{redir4}}}}}</td></tr> }}<!-- | ||
-->{{#if: {{{redir5|}}} | <tr><td><tt>{{{redir5}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir5}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir5}}}}}</td><td>{{ | -->{{#if: {{{redir5|}}} | <tr><td><tt>{{{redir5}}} (</tt><span class="plainlinks">[{{fullurl:Template:Country data {{{redir5}}}|redirect=no}} view]</span><tt>)</tt></td><td>{{flag|{{{redir5}}}}}</td><td>{{flaglink|{{{redir5}}}}}</td></tr> }}<!-- | ||
--></table> | --></table> | ||
====Using a redirect alias==== | ====Using a redirect alias==== | ||
* <tt><nowiki>{{flagicon|</nowiki>{{{redir1}}}<nowiki>}}</nowiki></tt> → {{flagicon|{{{redir1}}}}} | * <tt><nowiki>{{flagicon|</nowiki>{{{redir1}}}<nowiki>}}</nowiki></tt> → {{flagicon|{{{redir1}}}}} | ||
* <tt><nowiki>{{ | * <tt><nowiki>{{flaglink|</nowiki>{{{redir1}}}<nowiki>}}</nowiki></tt> → {{flaglink|{{{redir1}}}}} | ||
* <tt><nowiki>{{flag|</nowiki>{{{redir1}}}<nowiki>}}</nowiki></tt> → {{flag|{{{redir1}}}}} | * <tt><nowiki>{{flag|</nowiki>{{{redir1}}}<nowiki>}}</nowiki></tt> → {{flag|{{{redir1}}}}} | ||
}} | }} | ||
| Line 43: | Line 53: | ||
===Other information=== | ===Other information=== | ||
{{{{FULLPAGENAME}}/doc}} | {{{{FULLPAGENAME}}/doc}} | ||
}} | }} | ||
This is the documentation for '''Template:{{PAGENAME}}'''. It is automatically generated by [[Template:Country showdata]].<br/>Please {{purge|purge the cache}} after making any changes to this template.{{#ifexist:{{FULLPAGENAME}}/doc | This is the documentation for '''Template:{{PAGENAME}}'''. It is automatically generated by [[Template:Country showdata]].<br/>Please {{purge|purge the cache}} after making any changes to this template.{{#ifexist:{{FULLPAGENAME}}/doc | ||
|<br/>This template has a [[{{FULLPAGENAME}}/doc|/doc]] subpage for the purposes of | |<br/>This template has a [[{{FULLPAGENAME}}/doc|/doc]] subpage for the purposes of '''categories''' and documentation specific to this template. | ||
|{{#ifeq:{{PROTECTIONLEVEL:edit}}|sysop | |{{#ifeq:{{PROTECTIONLEVEL:edit}}|sysop | ||
|<br/>This template is [[WP:PROTECT|fully protected]] and any [[WP:CAT|categories]] and [[WP:ILL|interlanguage links]] should be added to the template's [{{fullurl:{{FULLPAGENAME}}/doc|action=edit&preload=Template:Category_interwiki/preload}} /doc] subpage, which is not protected. | |<br/>This template is [[WP:PROTECT|fully protected]] and any [[WP:CAT|categories]] and [[WP:ILL|interlanguage links]] should be added to the template's [{{fullurl:{{FULLPAGENAME}}/doc|action=edit&preload=Template:Category_interwiki/preload}} /doc] subpage, which is not protected. | ||
}} | }} | ||
}} | }} | ||
}}</includeonly><noinclude> | [[Category:Country data templates|{{{templatename|{{{alias}}}}}}]] | ||
</div> | |||
</includeonly><noinclude> | |||
{{documentation}} | {{documentation}} | ||
</noinclude> | </noinclude> | ||
Latest revision as of 14:02, 28 January 2020
[edit]
Template documentation
This template is used for documenting country data meta-templates used by the flag template system. The output of this template can be seen by directly viewing any of the templates in Category:Country data templates.