Difference between revisions of "Template:Flag"

Line 1: Line 1:
<div {{#if:{{{alternateclass|}}}|class="{{{alternateclass}}}"|class="flag-icon"}} style="display:inline-block; padding:0{{#if:{{{size|}}}||;width:23px}}">{{#if:{{{size|}}}||<div style="text-align:center">}}[[File:{{{1}}}.png|x{{#if:{{{size|}}}|{{{size|}}}|{{#if:{{{small|}}}|12px|14px}}}}|link={{{link|}}}]]{{#if:{{{size|}}}||</div>}}</div><noinclude>
<div {{#if:{{{alternateclass|}}}|class="{{{alternateclass}}}"|class="flag-icon"}} style="display:inline-block; padding:0{{#if:{{{size|}}}||;width:23px}}">{{#if:{{{size|}}}||<div style="text-align:center">}}[[File:{{{1}}}.png|x{{#if:{{{size|}}}|{{{size|}}}|{{#if:{{{small|}}}|12px|14px}}}}|link={{{link|}}}]]{{#if:{{{size|}}}||</div>}}</div><noinclude>
{{Tilt-A-Wiki template}}[[Category:Templates]]</noinclude>

Latest revision as of 15:08, 24 March 2020

Template documentation (for the above template, sometimes hidden or invisible)


This template produces a small flag image. It is generally not used directly, instead it is used by other templates. For cases where the flag is displayed beside the country name (such as the "Country" column in tables) please use Template:Country.

Usage[edit source]

This template works by linking to an image in Category:Flags. The following countries have flag files uploaded:

  • Afghanistan.png
  • Algeria.png
  • Angola.png
  • Argentina.png
  • Armenia.png
  • Australia.png
  • Austria.png
  • Azerbaijan.png
  • Bahrain.png
  • Bangladesh.png
  • Belarus.png
  • Belgium.png
  • Botswana.png
  • Brazil.png
  • Brunei.png
  • Bulgaria.png
  • Canada.png
  • Chile.png
  • China.png
  • Colombia.png
  • Costa Rica.png
    {{flag|Costa Rica}}
  • Croatia.png
  • Cyprus.png
  • Czech Republic.png
    {{flag|Czech Republic}}
  • Denmark.png
  • Dominican Republic.png
    {{flag|Dominican Republic}}
  • Ecuador.png
  • Egypt.png
  • Finland.png
  • France.png
  • Georgia.png
  • Germany.png
  • Greece.png
  • Guatemala.png
  • Honduras.png
  • Hungary.png
  • India.png
  • Indonesia.png
  • Iran.png
  • Iraq.png
  • Ireland.png
  • Israel.png
  • Italy.png
  • Japan.png
  • Kuwait.png
  • Kyrgyzstan.png
  • Latvia.png
  • Lebanon.png
  • Lithuania.png
  • Malaysia.png
  • Mexico.png
  • Mongolia.png
  • Morocco.png
  • Myammar.png
  • Netherlands.png
  • New Zealand.png
    {{flag|New Zealand}}
  • Nigeria.png
  • North Korea.png
    {{flag|North Korea}}
  • Norway.png
  • Oman.png
  • Peru.png
  • Philippines.png
  • Poland.png
  • Portugal.png
  • Qatar.png
  • Romania.png
  • Russia.png
  • Saudi Arabia.png
    {{flag|Saudi Arabia}}
  • Singapore.png
  • Slovenia.png
  • South Africa.png
    {{flag|South Africa}}
  • South Korea.png
    {{flag|South Korea}}
  • Spain.png
  • Sri Lanka.png
    {{flag|Sri Lanka}}
  • Sweden.png
  • Switzerland.png
  • Taiwan.png
  • Thailand.png
  • Tunisia.png
  • Turkey.png
  • Turkmenistan.png
  • UAE.png
  • UK.png
  • Uruguay.png
  • USA.png
  • Uzbekistan.png
  • Venezuela.png
  • Vietnam.png
  • Yemen.png

There are additional flag files uploaded, however these should generally not be used in articles.

Produces a small flag icon

Template parameters

This template prefers inline formatting of parameters.

Country name1

The name of the country. Please see the template description page for a list of countries.


no description


no description

Enable small sizesmall

If anything is entered into this parameter, a smaller flag is displayed. Use this for "former location" rows in tables.


no description


Visit Template:Flag/doc to edit this text! (How does this work?)