Jump to content

Template talk:Flag/Archive 1

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
Archive 1Archive 2

Palestine

{{Edit fully-protected}}

Please change Image:Palestinian flag.svg to Image:Flag of Palestine.svg. Thanks. Siebrand 23:01, 5 May 2007 (UTC)

The place to make that change is Template:Country data Palestine, which is not protected. CMummert · talk 15:34, 8 May 2007 (UTC)
Hmm, I already made that change. I have been mistaken. Thanks for checking here... Cheers! Siebrand 15:39, 8 May 2007 (UTC)

The United States flag isnt showing, it says the words "flag of United States". Can someone fix that. BeckyAnne(talk) 22:20, 14 September 2007 (UTC)

This happens from time to time, and is not a problem with this template. The image cache on Commons needs to be cleared. Andrwsc 22:32, 14 September 2007 (UTC)
Thanks for the little wiki lesson, I need those from time to time. BeckyAnne(talk) 23:12, 14 September 2007 (UTC)

 Kosovo has default alternative text "Flag of Kosovo". That's not a flag of Kosovo, it's the flag of the United Nations! Can someone fix that? (Stefan2 20:25, 23 October 2007 (UTC))

 Done Andrwsc 20:50, 23 October 2007 (UTC)

Issues with wikitables

Some of the flags screw up the parsing of wikitables. I've noticed this with the Canadian and English flags. But, this only happens when the row definition of the wikitable is in one line as opposed to it being broken up into individual lines per field/cell. Samples: non-working example: {| class="wikitable" !Field1
!Field2
!Field3
|-
|{{flag|USA}}||USA||howdy
|-
|{{flag|Canada}}||Canada||eh?
|-
|{{flag|Spain}}||Spain||hola
|-
|{{flag|England}}||England||cheers
|}
results in:

Field1 Field2 Field3
 USA USA howdy
 Canada Canada eh?
 Spain Spain hola
 England England cheers

working example: non-working example: {| class="wikitable"
!Field1
!Field2
!Field3
|-
|{{flag|USA}}||USA||howdy
|-
|{{flag|Canada}}
|Canada
|eh?
|-
|{{flag|Spain}}||Spain||hola
|-
|{{flag|England}}
|England
|cheers
|} results in:

Field1 Field2 Field3
 USA USA howdy
 Canada Canada eh?
 Spain Spain hola
 England England cheers

Any idea why this is happening with only some flags? --Kimontalk 16:42, 12 December 2007 (UTC)

Unwanted line break

{{editprotected}} For many countries (such as England) this template is now forcing a line break. (see Open de France) It makes many lists very hard to read, can anyone fix this? —MJBurrageTALK17:23, 12 December 2007 (UTC)

User:East718 has added {{pp-template}} to hundreds of country data templates, adding a line break to all of them. Damn. I shall try to fix this ASAP. Andrwsc (talk) 18:35, 12 December 2007 (UTC)
Glad to see someone is already working on this, as I have spent the past hour trying to figure out what was wrong with List of islands of the United States by area. Let me know if there is anything I can do to help. --Kralizec! (talk) 20:27, 12 December 2007 (UTC)
That would explain why I'm seeing what I posted in the section above. --Kimontalk 21:45, 12 December 2007 (UTC)
 Fixed All 893 country data templates have been repaired, so if you are seeing any more wierdness, try purging the template, clearing your own browser cache, or just wait for the servers to catch up... Andrwsc (talk) 21:47, 12 December 2007 (UTC)
Removing EPP, this appears to be fixed. Gimmetrow 16:35, 13 December 2007 (UTC)

Burma/Myanmar

Fix please For some reason, all of the country data outputs read "Burma" just like the main article, except {{flag|Myanmar}} which still reads "Myanmar." -Justin (koavf)·T·C·M 18:34, 9 January 2008 (UTC)

There is nothing to fix; this is precisely how it is intended. If you want your wikilink to display as "Burma", use {{flag|Burma}}. If you want your wikilink to display as "Myanmar", use {{flag|Myanmar}}. There are many contexts in which "Myanmar" is still the most appropriate name (United Nations, Olympics, FIFA, etc.), so that option is available for editors. In both cases, the flag template links to the Wikipedia target article at Burma, so no redirects are used. — Andrwsc (talk · contribs) 18:44, 9 January 2008 (UTC)

Nepal's flag broke

List_of_countries_by_population, this template is working improperly, showing the full Nepalese flag instead of a shrunk version. -130.215.112.208 (talk) 19:27, 9 April 2008 (UTC)

 Fixed Sorry! I was working on a solution to remove the border, as it looks odd with this flag, and I tested my solution. Interestingly, it worked when {{flag|Nepal}} is invoked in "normal" wiki text, but inside tables it broke spectacularly, as you saw. I shall investigate further. — Andrwsc (talk · contribs) 20:03, 9 April 2008 (UTC)

Interwiki

Please add da:Skabelon:Flag User:Nillerdk (talk) 20:29, 24 April 2008 (UTC)

Croatia

Please use Image:Civil Ensign of Croatia.svg as Croatian flag icon. --Maestral (talk) 13:28, 1 June 2008 (UTC)

Why? — Andrwsc (talk · contribs) 15:25, 1 June 2008 (UTC)

Question on using this template in lists

List of Los Angeles Lakers first and second round draft picks and other NBA and other similar lists use a nationaly column for the players, so is it possible to display these templates so that the country name isn't wikilinked. because currently it just creates over-wikilinking of the countries. --Gman124 talk 23:42, 27 June 2008 (UTC)

Instead of using {{flag|USA}}, just use {{flagicon|USA}} USA. — Andrwsc (talk · contribs) 17:51, 28 June 2008 (UTC)

Switzerland

The current {{flag|Switzerland}} template, gives a 20x20px image. While all others are 22x15px. This causes tables to be out of line a bit. Perhaps it can be changed to 15x15 (with style="margin: 0px 3px 0px 2px"), or a 22x15 format - even though the official format is a square. =Species8473= (talk) 12:32, 17 July 2008 (UTC)

The current flag template system does not support unique sizing per flag. The current size of 22x20px was chosen as a "best fit" compromise for 3:2, 5:3, 2:1, and even 1:1 flag aspect ratios, so that's why you see a maximum width of 22 pixels and a maximum height of 20 pixels. I don't think there is anything we can easily do for this template (i.e. {{flag|Switzerland}}), but I've changed Template:CHE (also used through the redirect at {{SUI}}) so that it bypasses the flag template system and renders the flag directly, thereby allowing the custom size and spacing. Hopefully this is a useful alternative for you. — Andrwsc (talk · contribs) 18:19, 17 July 2008 (UTC)
I don't like it. Both "Flag|Switzerland" and "CHE" should render the same size and Just Work™. It should be simple and not confusing in a way that won't be noticeable by the mass that does not care for two different sizes.--Bxj (talk)
please add the arabic interwiki ar:قالب:علم ar:قالب:علم--Heshamdiab116 (talk) 13:14, 12 November 2008 (UTC)

problems with some proportions

Many flags don't show up properly, including those with the proportions 1:2 (Ireland, UK, UAE, Hungary, Nigeria, Malaysia, Kuwait), 1:19 (US), and 3:5 (Bangladesh). Those flags have a "blank" stripe at the top of their symbols. Could you please change that? Thanks, Ibn Battuta (talk) 18:25, 9 December 2008 (UTC)

I think you are referring to the standard border attached to almost all flags. — Andrwsc (talk · contribs) 19:09, 9 December 2008 (UTC)

Text Alignment

The text doesn't seem to be aligned with the flag properly; it is slightly higher.

 United Kingdom

ajmint (talkemailcontribssubpages) 16:08, 17 December 2008 (UTC)

Northern Ireland flag needs removal

This needs to be removed there is no active flag for Northern Ireland and it's misleading when you add Northern Ireland to the list of countries in an article (using the flag template since the others all do) it uses the old one that hasn't been used for decades

http://wikipedia.org/wiki/Great_Britain?action=history for an example of the confusion this can cause

--87.112.55.149 (talk) 20:13, 14 January 2009 (UTC)

Discussed extensively elsewhere. The solution is to use that template only for appropriate articles, not to delete it so that it can't be used on any article. And "hasn't been used for decades" is a POV that is untrue. See the FIFA, CGF and PGA TOUR websites for three high-profile, contemporary, reliable sources that use that flag. — Andrwsc (talk · contribs) 20:39, 14 January 2009 (UTC)
Just because sports websites use it doesn't mean it's currently in use for any country/locality officially - it simply is not, so it shouldn't be on here any more than a flag for London should be... --87.112.55.149 (talk) 22:49, 14 January 2009 (UTC)
I think you completely miss the point. Just because a template is inappropriate to use on some pages doesn't mean we should delete it so that it can't be used on any page. Regardless, this talk page is clearly not the best place for this discussion. If you feel there could be consensus, feel free to nominate Template:Country data Northern Ireland and Template:NIR for deletion, and let the discussion take place on the TfD page. — Andrwsc (talk · contribs) 23:07, 14 January 2009 (UTC)
The Ulster Banner is the flag of the IFA and you will find most the the usage on wiki of this flag is for soccer players Gnevin (talk) 17:10, 24 January 2009 (UTC)

Northern Ireland

 Northern Ireland: This flag apparently is wrong. When using it, it is edit-warred out. Even to the point of reverting whole other changes that have nothing to do with this flag. You can not blame me for an error in this template when I use it. If Northern Ireland currently has no flag, it should not be used in this template. If somebody would want to use the 'old' flag (which it apparently is), they should not do it using a template afaik meant for showing current flags. nftaDaedalus (talk) 00:58, 6 February 2009 (UTC)

alt text

According to WP:MOS MOS:FLAGS flags (all flags) should have text for the visually impaired. To provide alt text, simply add the description to the end of the image markup: [[Image:PictureName.jpg|300px|right|Description of the image]]. The United States flag and all the examples on this template page do not have alt text. SunCreator (talk) 04:16, 20 March 2009 (UTC)

The alt attribute was removed a few weeks ago because of negative feedback about WP:Accessibility. This template is used for "inline" icons, not standard images to the left or right of article prose as in your example. Therefore, screen readers would say "flag of the United States United States" when rendering the output of {{flag|United States}}, for example. It was felt that the screen reader output should only say the country name, which is why the alt attribute was disabled. — Andrwsc (talk · contribs) 04:29, 20 March 2009 (UTC)
I don't understand how you say it would be "flag of United States United States", it currently is blank entirely without an country name. SunCreator (talk) 11:50, 20 March 2009 (UTC)
What I mean is that this template always renders both the flag and the country name. For example, {{flag|United States}} United States. If the image had the alt attribute set (as it used to), a screen reader would say "flag of the United States" for the image, followed by "United States" for the wikilink, or a complete result of "flag of the United States Unites States". It is much better to simply say "United States", which means the alt attribute should be blank for the image and only the wikilink is read. — Andrwsc (talk · contribs) 16:39, 20 March 2009 (UTC)
I'm afraid this analysis is incorrect. When a typical screen reader sees an image with a link but no alt text, it reads the title of the image (or even the image URL, if that's all it has), because the image has a function (the link) which the user may need to know about. For example, for " United States" a screen reader might say something like "Flag of the United States period ess vee gee United States". To fix the problem, the image should not have a link, as discussed in WP:ALT #When to specify. For example, for " United States" (where the image itself is not linked) a screen reader might say just "United States", which is much better. I have followed up with the obvious fix proposal at Wikipedia talk:WikiProject Flag Template #Fix for accessibility disaster. Eubulides (talk) 07:42, 12 July 2009 (UTC)

African Union

Any chance of getting a flag template for the African Union? Thanks. - Jonathon A H (talk) 21:37, 24 July 2009 (UTC)

No chance, as File:Flag of the African Union.svg is copyrighted, and can only be used on a very limited number of pages (i.e. on African Union and Flag of the African Union, but that's about it) per WP:Non-free content criteria policy. This is the same situation as we have with the NATO flag, for which no flag template exists (or can exist). — Andrwsc (talk · contribs) 21:42, 24 July 2009 (UTC)

Proposal for documentation

Please see my proposal to use centralized documentation for all uses of the flag template. —TheDJ (talkcontribs) 12:38, 6 December 2009 (UTC)

World Bank

I've seen that some one has attempted to use this template on the Humanitarian response to the 2010 Chile earthquake under Intergovernmental organizations in conjunction with the World Bank.

However World Bank has no actual "entry" here as far as I can tell, as this is what appears:

 [[File:|22x20px|border |alt=|link=]] World Bank

I was going to add it in myself, however I don't believe I can do easily without risking breaking the template, so I'm asking if someone else who knows what they're doing can do it. -- Droideka75 (talk) 06:55, 2 March 2010 (UTC)

There is no flag for the World Bank, so there shouldn't be an attempt to use a flag template in those articles. Also, File:World Bank Logo.svg is a non-free image, and therefore cannot be used as a non-flag icon for the World Bank in those articles either. — Andrwsc (talk · contribs) 17:23, 17 May 2010 (UTC)

Non-breaking space

{{editprotected|Template:Flag}} I have come across another line break issue. I don't know what was the problem above but could someone add an NBSP between the flag icon and the name string? E.g. if you have a look at {{States of Germany}} you'll see some nasty breaks depending on your screen width. De728631 (talk) 22:20, 16 May 2010 (UTC)

This seems to be an issue with Template:Country flag2, which does actually use a non-breaking space. So I'm not sure what's going wrong. I'll ask Andrwsc to comment. — Martin (MSGJ · talk) 14:56, 17 May 2010 (UTC)
Yes, there has always been an   used with this template, and you can verify that with the output of Special:ExpandTemplates. I'm not sure why that non-breaking space is not being respected. — Andrwsc (talk · contribs) 17:20, 17 May 2010 (UTC)
I noticed that the &nbsp; is inside the <span> tags, could that be the reason? Maybe only the icon file itself should be included. De728631 (talk) 19:16, 17 May 2010 (UTC)
Nope, I just previewed the output HTML markup for {{States of Germany}} minus those spans and it still renders the same. — Andrwsc (talk · contribs) 19:28, 17 May 2010 (UTC)
Well previewing templates doesn't seem to work anyway, at least not for me. For some reason certain changes always take a while to become visible even when they're fully implemented and saved. De728631 (talk) 19:50, 17 May 2010 (UTC)

Taiwan

Currently {{TWN}} produces " Taiwan". What can be done to display "Taiwan Taiwan (Republic of China)"? 203.198.25.249 (talk) 12:40, 17 May 2011 (UTC)

I don't think we need to resolve the display to "Republic of China". The default link is already redirected to Republic of China. De728631 (talk) 16:58, 17 May 2011 (UTC)
You can use {{flag|ROC|name=Taiwan (Republic of China)}} to get  Taiwan (Republic of China). If you really don't want the "Taiwan" text to be part of the wikilink, then you can use {{flagdeco|ROC}} Taiwan ([[Republic of China]]) to get precisely what you've asked for above. — Andrwsc (talk · contribs) 18:36, 17 May 2011 (UTC)

Northern Ireland

What flag should be displayed for the province? The flag in FIFA event, or the Union Flag? 203.198.25.249 (talk) 12:40, 17 May 2011 (UTC)

What is the context of the flag usage? In some contexts, no flag is appropriate, in others, the Ulster banner is acceptable. — Andrwsc (talk · contribs) 18:36, 17 May 2011 (UTC)

U.S. flag

It would be better to use the Pantone colors like this flag : — Preceding unsigned comment added by Mightymights (talkcontribs) 21:42, July 29, 2011 (UTC)

Edit request: Flag of western Sahara

Hi,
Can you please replace the flag used for Western Sahara by this, per WP:NPOV and Wikipedia:Western Sahara Infobox/Vote.

The territory is disputed, displaying that flag to refer to the territory is clearly partisan. Consensus already reached, for the change of the flag at the page linked above. The flag that currently appears should only be under {{flag|SADR}} or {{flag|Sahrawi Arab Democratic Republic}}
Regards --Tachfin (talk) 08:02, 21 August 2011 (UTC)

Also, take this consensus into account --Tachfin (talk) 08:29, 21 August 2011 (UTC)
That's not a flag, so shouldn't be used for a flag icon per WP:MOSICON. The better solution would be to update transclusions of Template:Country data Western Sahara and Template:Country data ESH, but in any case, there is nothing whatsoever that needs to be done to this template. — Andrwsc (talk · contribs) 19:06, 23 August 2011 (UTC)

I think that Libya deserves a flag makeover. Who is in favor of recognizing the NTC? Rainbow Dash !xmcuvg2MH 01:29, 24 August 2011 (UTC)

Wikipedia is not a soapbox. I would wait until there's official recognition by the UN of the transition of power. Wikipedia can wait a month or so for this. --Bxj (talk) 03:12, 24 August 2011 (UTC)
It seems that it has already been done. Considering that many countries already recognise the NTC, I don't think it's much of an issue. EricLeb01 (Page | Talk) 00:52, 12 September 2011 (UTC)

Linking to articles other than the main country article

The page List of countries with floating currencies uses this template for every country on the list, but for that page, it makes more sense to link to the article on the country's currency. Is this possible with this template? D O N D E groovily Talk to me 23:41, 6 February 2012 (UTC)

Similarly, on historical articles it is sometimes more appropriate to link to a historical country's article. E.g. {{flag|SVK|1938|name=Slovak Republic}} Slovak Republic where the link is to Slovakia, but should be to Slovak Republic (1939-1945). In this particular case the choice of link target could probably be resolved via the country data templates. Hairy Dude (talk) 00:51, 15 June 2016 (UTC)
There is a separate data template for the WWII Slovak Republic: {{flag|Slovak Republic (1939–1945)|name=Slovak Republic}} Slovak Republic. You can set the article to link to using the {{flagg}} template, though creating a new data template is the better solution for linking to a historical country with its own article. SiBr4 (talk) 20:36, 15 June 2016 (UTC)
The {{flagcountry}} template is most commonly used for these situations. {{flagcountry|Slovak Republic (1939–1945)}} produces  Slovakia. — Andrwsc (talk · contribs) 00:25, 28 June 2016 (UTC)

Non-breaking space

Would it be possible for the space between the flag and the label to be a non-breaking space? There are sometimes situations where the flag appears at the end of a line and the corresponding text is at the start of the next one. (See Indian Ocean#Bordering countries and territories for example, although I suppose it depends on your screen size.) I think it would be better if the flag and text were always adjacent. Bazonka (talk) 06:39, 23 July 2012 (UTC)
I've just noticed that this has already been discussed earlier on this talk page. In any case, it's still not fixed, so worth revisiting. Bazonka (talk) 06:41, 23 July 2012 (UTC)

Seems unlikely an IP editor will get a reply if you didn't, but the problem you describe still remains, two months later. 67.101.5.42 (talk) 05:53, 26 September 2012 (UTC)
I've had another look at it and have now checked the documentation at Wikipedia:WikiProject Flag Template. It says that the template invokes the following line of code ({{Flag/core}}):
<span class="flagicon">[[File:Flag of Spain.svg|22x20px|border |alt=|link=]]&nbsp;</span>[[Spain]]
Example with unwanted line break:
Foo
Administration
xxxxxxxxxx xxxxxxxxxxxxxxxxxxxx Spain
A quick workaround might be wrapping a <div> around the existing code in {{Flag/core}}, like
<div><span class="flagicon">[[File:Flag of Spain.svg|22x20px|border |alt=|link=]]&nbsp;</span>[[Spain]]</div>
which produces
Foo
Administration
xxxxxxxxxx xxxxxxxxxxxxxxxxxxxx
I'm not much of a template coder but I can't see how this change would cause any bugs. So I suggest we implement that. De728631 (talk) 13:40, 27 September 2012 (UTC)
P.S. on a second look, a simple <div></div> won't work because it creates columns. Nowrap should do it though, and there is a huge unanswered list of proposals at Template talk:Flag/core#Proposals: Specify “link=” value and nowrap flag image with text. De728631 (talk) 13:54, 27 September 2012 (UTC)

Comment

Just to say that my instinct is that {{flag|X}} would deliver the flag of X, not the flag of X followed by X's name. In other words, it seems to me that {{flag|X}} should behave along the lines of {{flagicon|X}} rather than {{flagcountry|X}}. Hope that doesn't sound ungrateful, though. 213.246.91.158 (talk) 21:56, 14 November 2012 (UTC)

When these templates were developed 7 or 8 years ago, that would have been more logical. But now with hundreds of thousands of transclusions, it's too late to swap them, I think. — Andrwsc (talk · contribs) 00:01, 21 March 2013 (UTC)

Optionally not linking countries

Could we have an additional parameter, similar to 'links=no' on the {{lang-xx}} templates, to bypass linking of the country? The MOS recommends not linking well-known locations such as United States, for example, so this would provide that facility for flags too. Colonies Chris (talk) 15:16, 20 March 2013 (UTC)

Use {{flagu}}. — Andrwsc (talk · contribs) 23:59, 20 March 2013 (UTC)
Thanks. This template will be very useful for reducing overlinking. It would be helpful if it were documented at Wikipedia:WikiProject Flag Template. Colonies Chris (talk) 11:42, 27 March 2013 (UTC)

Fix Swiss/Nepal/Vatican flag height

The tall flags should be fixed to use height x17px (rather than default: 22x20px) so that they would fit typical line-height of text, but that involves padding their width by "&nbsp;" prepended before the country name=xxx. So, 5 templates would be affected to make the fix, using 20x17px as the size:

           Size 22x20px
text  France
text   Switzerland (as 22x20px)
text  Italy
text  Vatican City (as 22x20px)
text  India
text    Nepal   (as 22x20px)
text  Pakistan
           Size 20x17px
text  France
text    Switzerland (as 20x17px)
text  Italy
text   Vatican City (as 20x17px)
text  India
text     Nepal   (as 20x17px)
text  Pakistan

As shown in the table above, the "text" lines are evenly spaced when size of those 3 flags is reduced to 20x17px. Because the prior width of the Swiss/Nepal/Vatican flags was 20px, rather than 22px, then the added name-padding by &nbsp will also better align those flag names in current lists where they are being displayed. Only the Swiss/Nepal/Vatican flags would be affected by this change, and Template:Flagicon will never put &nbsp. Because the size code "20x17px" is so unusual, then it would be unlikely to be used as a custom size by editors showing flags, and the extra space would only be triggered when showing the name with the Swiss/Nepal/Vatican flags. As for performance considerations, a #ifeq function can run with 1/800 second, and so the formatting of flags by templates {flag} or {flagu} would increase by only 2/800 second for each flag shown in a page. Hence, showing 100 flags in a page would increase formatting by only 1/4 (2/8) second (0.250s) longer. Any questions? -Wikid77 (talk) 11:33, 3 June, revised 13:22, 8 June 2013 (UTC)

Reduce Swiss/Nepal/Vatican flags

As requested for over 2 years, the Swiss/Nepal/Vatican flag icons should be 20x17px. See related discussions:

To reduce the flag height, but still align country names, then 5 templates must be changed, as follows:

The sandbox version, Template:Flag/core/sandbox, contains the updated logic to align the smaller flag icons. After the templates have been updated, the following testcases should match:

Testing of results
{{flag|...}} Currently Expected comments
{{flag|Nepal}}    Nepal    Nepal (shift name +2 spaces)
{{flag|Germany}}  Germany  Germany (unchanged)
{{flag|Switzerland}}   Switzerland     Switzerland  (shift name +1 space)
{{flag|Vatican City}}  Vatican City  Vatican City (shift name +1 space)
{{flag|Italy}}  Italy  Italy (unchanged)
 
{{flagu|...}} Currently Expected comments
{{flagu|Nepal}}    Nepal    Nepal (shift name +2 spaces)
{{flagu|Germany}}  Germany  Germany (unchanged)
{{flagu|Switzerland}}   Switzerland     Switzerland  (shift name +1 space)
{{flagu|Vatican City}}  Vatican City  Vatican City (shift name +1 space)
{{flagu|Italy}}  Italy  Italy (unchanged)

Because the fixes, for flag height+alignment, have involved changing 5 related templates, for alignment within a wikitable, then it had remained uncorrected for over 4 years. Few people understood the interactions between {Country_data_Switzerland} and {Flag} with {Flag/core}, etc. Plus changing the sandbox versions, and showing the test results inside wikitables, can be very tedious to demonstrate the precise typesetting of 3 flag icons, among over 350 similar flags.
Impact: {flag/core} has "334,868 transclusions" and {country_data_Switzerland} has 27,409, etc. -Wikid77 (talk) 13:22, 8 June 2013 (UTC)

Thank you for the detailed release notes. These exceptions are now added as well to the experimental (and incomplete) Template:FlagiconLua - see diff.--QuimGil (talk) 05:20, 9 June 2013 (UTC)
Done. Thanks for your work, and for the detailed description of the changes. It made implementing this request pretty easy. Also, sorry about the long wait. Best — Mr. Stradivarius ♪ talk ♪ 10:37, 13 June 2013 (UTC)

Default sizes must use #if to work

19 June 2013: Unfortunately, because of empty parameter "size=" then using "{{{size|20x17px}}}" has failed to set the default size, which is replaced with the empty value as passed. Instead, the 3 {country_data...} templates must check "#if:{{{size|}}}" to set the default size. Also, some users think x17px is too high for their browsers, so 20x16px is being used for the Swiss and Vatican flags, but x17px for Nepal:

I have modified the table of flags, above, to show the x17px and x16px results in the "Expected" column, to compare results after updating those 3 templates. -Wikid77b (talk) 06:12, 19 June 2013 (UTC)

 Done De728631 (talk) 15:12, 19 June 2013 (UTC)
Is the done relative to the default size only or are the 3 flag sizes above also part of the decision? Sorry, I'm just trying to match the current implementation for Template:FlagiconLua.--QuimGil (talk) 15:21, 19 June 2013 (UTC)

Other flags

Have the other flag icons somehow been affected by this change? Only these three flags were supposed to change, but a lot of other icons now look very weird (Monaco, Niger, DR Congo, Norway, Denmark etc.). 92.81.68.23 (talk) 15:53, 4 August 2013 (UTC)

Alignment in table

Thread moved from Template_talk:flagicon:

Country Code
 USA 1
  CHE 2
   NPL 3
 GBR 4
When the flag or flagicon template is used in a table as in the example on the right, the country names are not aligned. Is there an option to make them aligned, for example, by putting appropriate margins on the icons so that they are all the same widths? Thanks! cmɢʟee୯ ͡° ̮د ͡° ੭ 13:06, 7 June 2013 (UTC)
This question is about Template:Flag and therefore could be better placed at Template_talk:Flag. Flagicon doesn't have label. (Your suggestion is good, but it would require a calculation of the right margin based on the size of the image. Technically doable, but requires improving the template.)--QuimGil (talk) 16:13, 7 June 2013 (UTC)
  • Similar to Swiss/Nepal/Vatican problem: Above, "#Fix Swiss/Nepal/Vatican flag height" describes a permanent fix, but for now, set the size as "x17px" with &nbsp spacing in each flag:
{{flag|&nbsp;Switzerland|size=x17px}}    Switzerland A
{{flag|GBR}}  GBR B
{{flag|&nbsp;&nbsp;NPL|size=x17px}}      NPL C
{{flag|&nbsp;Vatican City|size=x17px}}   Vatican City D
{{flag|USA}}  USA E
Even with the lead spaces "&nbsp;" each nation name is linked properly. -Wikid77 (talk) 11:03, 8 June 2013 (UTC)
code gives note
{{flagicon|ITA}} ABCDE Italy ABCDE
{{pxsp|3}}{{flagicon|SUI}}{{pxsp|4}} ABCDE Switzerland ABCDE 3px space on the left & 4px space on the right
{{flagicon|RUS}} ABCDE Russia ABCDE
{{pxsp}}{{flagicon|VAT}}{{pxsp|6}} ABCDE Vatican City ABCDE 1px space on the left & 6px space on the right
{{flagicon|USA}} ABCDE United States ABCDE
{{pxsp|6}}{{flagicon|NPL}}{{pxsp|5}} ABCDE Nepal ABCDE 6px space on the left & 5px space on the right
Maiō T. (talk) 23:54, 26 July 2013 (UTC)

Update: There is now {{flaglist}} which automatically aligns country names without having to manually add spaces. SiBr4 (talk) 21:50, 15 August 2014 (UTC)

Attn Sysops: Ascension Island new flag

Please replace the Union flag by the new Ascension Island Flag: Flag_of_Ascension_Island.png Thanks in advance, --— J. F. B. (me´n parlar) 18:14, 14 July 2013 (UTC)

I'm sorry but we can't use the new flag in a template because the design of the shield is copyrighted and unfree. The images of the flags of Ascension island are being used under a fair-use rationale for specific articles only, and the use in illustrative templates is not covered by our non-free content criteria. De728631 (talk) 18:29, 14 July 2013 (UTC)
I have made a request at Wikipedia:Graphics Lab/Illustration workshop#Flag and coat of arms of Ascension Island for an artist's help in generating a new image, but so far that request has been ignored. — Andrwsc (talk · contribs) 05:52, 15 July 2013 (UTC)

Korean Flag

The template {{Flag|Korea}}:  Korea links to a historical flag of Korea. The template {{Flag|KOR}}:  KOR has the correct one. Sander.v.Ginkel (talk) 09:59, 3 September 2013 (UTC)

You need to use {{flag|South Korea}} (or {{KOR}}). "KOR" is the country code for South Korea. Template:Country data Korea links to the article at Korea, which describes the historical state prior to the 1945 division. — Andrwsc (talk · contribs) 18:29, 3 September 2013 (UTC)

Coat of arms Priboj - new

http://priboj.rs/o-priboju/znamenja-opstine Markojanjusevic (talk) 02:46, 3 November 2013 (UTC)

 Not done. First of all, this template is for widely used flags like those of countries and provinces, but it's not meant for flags of individual towns that are unlikely to be used across Wikipedia. Apart from that there is currently no free image of particular this flag avalaible at Commons:Category:Priboj. De728631 (talk) 15:11, 3 November 2013 (UTC)

Kingdom of Yugoslavia

I edit articles about ships lost in the Second World War, in which templates to display historic flags are often useful. I have found how to do this for countries including Canada, Egypt, Greece, Palestine and Syria but not Yugoslavia. I assumed that the syntax for the Kingdom of Yugoslavia's flag would be {{flag|Yugoslavia|1918}} for the civilian flag. I have no idea what the syntax for the naval ensign (adopted in 1922) would be. Anyone please help? Thankyou, Motacilla (talk) 20:56, 12 December 2013 (UTC)

{{flag|Kingdom of Yugoslavia|naval}} Kingdom of Yugoslavia. Or use {{flagcountry}} for  Yugoslavia, where the link target is still Kingdom of Yugoslavia but the display text is simply "Yugoslavia". — Andrwsc (talk · contribs) 17:16, 13 December 2013 (UTC)

Edit request

Resolved
 – Fixed

Replace File:Flag of the Commonwealth of Nations.svg, which is pending deletion at Commons with File:Flag of the Commonwealth of Nations.jpg, which is a file I uploaded locally and tagged as "Do not move to commons". CourtlyHades296 (talk) 00:11, 24 December 2013 (UTC)

You already did that yourself by changing {{Country data Commonwealth of Nations}}. Just let the system get rid of the svg icons in the cache. If you look at my user sandbox you'll see that all these related templates now display icons based on the local jpg file. De728631 (talk) 01:58, 24 December 2013 (UTC)

Default sort

There are countries that have to be sorted in tables according to the main part of their names, instead of the first words of their names, e.g., the Federated States of Micronesia and the FYRO Macedonia have to be placed under #M, and the Republic of the Congo under #C. Is there any built-in default sort template within the {{flag}} template? 116.48.155.127 (talk) 21:06, 18 February 2014 (UTC)

Not built in. You have to use {{sort}}. — Andrwsc (talk · contribs) 00:48, 19 February 2014 (UTC)
Would it be better to have it built-in, or to add such an option? 116.48.155.127 (talk) 18:07, 19 February 2014 (UTC)
It would add a non-trivial amount of complexity to what needs to be a streamlined template. — Andrwsc (talk · contribs) 18:42, 19 February 2014 (UTC)
So would the solution be like {{sort | Congo, Republic of the | {{flag|Republic of the Congo}} }}, for example? 116.48.155.127 (talk) 16:09, 20 February 2014 (UTC)
Yes, precisely. — Andrwsc (talk · contribs) 16:24, 20 February 2014 (UTC)
Any chance adding it to the flag template? 116.48.155.127 (talk) 17:21, 20 February 2014 (UTC)
Say, adding a parameter like "|sort=Congo, Republic of the" 116.48.155.127 (talk) 17:23, 20 February 2014 (UTC)
Hello? 116.48.155.127 (talk) 18:03, 24 February 2014 (UTC)
That was already answered with "It would add a non-trivial amount of complexity to what needs to be a streamlined template."  — SMcCandlish ¢ ≽ʌⱷ҅ʌ≼  00:52, 17 November 2014 (UTC)

kyrgyzstan

no Invalid

Unless I missed it, there doesn't appear to be a kyrgyzstan flag. Can we get it added? --CyberXRef 23:24, 20 February 2014 (UTC)

Scratch that, it's there, no action necessary. My bad! --CyberXRef 23:38, 20 February 2014 (UTC)

United States flag as used in flagicon

Cross-posted from Template_talk:Flagicon#United_States_flag (I don't know what the right place is for this.)

May I make a suggestion for the display of the US flag as an icon? The current default results in a icon of 23x12px. However the US flag has 13 stripes. The mapping of 13 stripes to 12 lines results in blurry stripes:

United States 23x12px: Icon width of 23px (currently the default)
United States 24x13px: Width of 24px

I don't know what the best answer to this is, but I would suggest either changing the default (for all) to 24px, or having an icon for the US flag with 23x13px (accepting that the proportions are then slightly off from the nominal 10:19). Tony Mach (talk) 18:24, 5 March 2014 (UTC)

Agree it looks better. Would there be any technical problem making all the flag icons a hair larger? It would be a boon to those of us with crappy eyesight, and have negligible other effect I can think of (even if some tables have been unwisely coded to use specific column widths, I believe they'd expand to encompass the content anyway, wouldn't they? If not, it's a good excuse to fix tables to stop using specific pixel-width columns. It would be a poor idea to make only this one flagicon display larger, as that would have a negative effect on display with other flags.  — SMcCandlish ¢ ≽ʌⱷ҅ʌ≼  00:36, 17 November 2014 (UTC)

Correct Swiss Flag

Request moved to the probably correct(?)/better place to be discussed: Template_talk:Country data Switzerland#Correct Swiss Flag

-- ZH8000 (talk) 03:41, 2 June 2014 (UTC)


Free France

This article was recently moved, and I'm not sure of where in Template:Country data France or Template:Country data Free French Forces changes have to be made (or moved to Template:Country data Free France), so that {{Flag|Free France}} creates a link to Free France, and not to Free French Forces as now. Thanks for any help. walk victor falk talk 09:40, 9 July 2014 (UTC)

The article linked to is specified by the |alias= parameter in a country data template (Country data Free French Forces in this case; Country data France always links to France). Whether the template is titled "Country data Free French Forces" or "Free France" does not matter for its output or usage as long as the other title is a redirect.
While it is usual for flag templates to directly link to the right article, the guideline WP:NOTBROKEN also applies. SiBr4 (talk) 10:13, 9 July 2014 (UTC)
Thank you for your help. FF and FFF are not synonyms, but two distinct but overlapping topics with one with a wider scope than the other that are treated within a single article, which introduces an issue of WP:EGG. walk victor falk talk 15:19, 9 July 2014 (UTC)
I'm with victor falk on this one; WP:NOTBROKEN doesn't apply in this case. A subtopic and the topic of which it is a subtopic are not the same thing.  — SMcCandlish ¢ ≽ʌⱷ҅ʌ≼  00:48, 17 November 2014 (UTC)

Swedish double-tailed flag

Missing British codes

The FIFA and ISO 3166-2:GB codes for Scotland and Wales differ. We already support FIFA's WAL and SCO but should also permit WLS and SCT, as we really can't expect anyone but experts in language code differences to distinguish between them. Some sports (snooker being one, if I recall correctly) use the ISO codes, since they're not football.  — SMcCandlish ¢ ≽ʌⱷ҅ʌ≼  23:20, 16 November 2014 (UTC)

Also, there are three ISO 3166-2:GB national codes we're not supporting yet: EAW (England and Wales = Union Jack minus the Scottish component); GBN (Great Britain = UK); UKM (United Kingdom = UK). The first of these has historic significance and has been a real flag, before union with Scotland. The other two are just the Union Jack again, and should be supported for completeness.  — SMcCandlish ¢ ≽ʌⱷ҅ʌ≼  23:33, 16 November 2014 (UTC)

And more. Between ISO 3166-1 alpha-2, ISO 3166-1 alpha-3, and ISO 3166-2:GB I've found several more we're not supporting yet: IM (Isle of Man), GBM (Isle of Man), JE (Jersey), GBJ (Jersey), GG (Guernsey), GBG (Guernsey), GBA (Alderney).  — SMcCandlish ¢ ≽ʌⱷ҅ʌ≼  00:09, 17 November 2014 (UTC)

Of all ISO codes, currently only 3166-1 alpha-3 codes consistently exist as redirects; alpha-2 codes generally don't. The currently existing two-letter aliases are a jumble of ISO 3166-1 alpha-2 codes, postal codes for the US and Canada (equal to the ISO 3166-2 codes save for the US-/CA- prefix), and acronyms, none complete. To me those are not precedents to create redirects for the alpha-2 codes for the Crown Dependencies (GG, IM, JE).
GBG, GBM and GBJ, as well as GBA, are indeterminately reserved; the current actual alpha-3 codes of the CDs are GGY, IMN and JEY, which are existing data template aliases. No other indeterminate reservations exist as data templates except some which are current FIFA or IOC codes (BRU, SLO, WAL), and ROK as a special case. There are no ISO codes WLS, GBN etc. at all; the ISO 3166-2 codes for the subdivisions of the UK are GB-WLS, GB-GBN etc. The only ISO 3166-2 country data redirect that currently exists is IN-KA (Karnataka, India).
Also, since when is "Great Britain = UK"? SiBr4 (talk) 10:35, 17 November 2014 (UTC)

Commonwealth of Nations

The example for Commonwealth of Nations, in Examples, doesn't show the flag:

{{flag|Commonwealth of Nations|name=Cmnwlth}}

produces

{{flag|Commonwealth of Nations|name=Cmnwlth}}

with empty space where the flag should be. --Thnidu (talk) 04:33, 27 January 2015 (UTC)

This is intentional; see Template:Country data Commonwealth of Nations. Because no free image of the actual Commonwealth flag is available, a transparent placeholder image is used. SiBr4 (talk) 08:57, 27 January 2015 (UTC)
@SiBr4: Thank you for the explanation and the pointer. I've added your explanation, without signature (which would be out of place there) but with a pointer to this Talk §, to Template:Country data Commonwealth of Nations/doc. It appears on Template:Country data Commonwealth of Nations under Other information. Since that section is near the bottom of the page and it looks as though the image is simply missing, I've boldfaced the text to make it more conspicuous. --Thnidu (talk) 17:44, 28 January 2015 (UTC)

Addition that makes possible to use [[]] in the first parameter

Hello. I just added some code to the Template:Flag/sandbox, tested in three other wikipedias. It works very fine there. It makes possible to use [[ and ]] around the name of the country. If the template is used in infoboxes, it's now possible to use a little bit smaller code there to create a link to an article.

* {{Flag|USA}}
* {{Flag|[[USA]]}}
* {{Flag/sandbox|[[USA]]}}

returns

  •  USA
  • {{country data USA|flag/core|name=USA|variant=|size=}}
  • {{country data USA|flag/core|name=USA|variant=|size=}}

The added code use the Lua-module Module:String. Greetings --Tlustulimu (talk) 13:00, 28 April 2015 (UTC)

Hi, it's been previously requested here and elsewhere that it would be useful to have the flag icon functionality but with the option to link to an article other than the main article for the country in question, e.g.  Peru appropriately links to Peru, but if the article is all about tennis, then linking to Tennis in Peru would be more appropriate, possibly with something like:

{{flag|Peru|link=Tennis in Peru}}

What does everyone think? Facts707 (talk) 16:42, 6 September 2015 (UTC)

Since adding parameters to most flag templates isn't as easy as it seems (it would require adding pass-through parameters to 6,317 templates), many separate templates exist with different output formats. For prefix links, like in your example, there is {{flag+link}}:
  • {{flag+link|Tennis in|Peru}} Peru
The general {{flagg}} can handle prefix/suffix links as well as normal country links, and allows overriding the link target in either case:
  • {{flagg|unc|Peru}} Peru
  • {{flagg|unc|Peru|link=Article title}} Peru
  • {{flagg|unp|Peru|pref=Tennis in}} Peru
  • {{flagg|unp|Peru|pref=Tennis in|flink=Article title}} Peru
SiBr4 (talk) 17:11, 6 September 2015 (UTC)
Wow, that's great - thanks much! I found {{flag-article}} but that one is intended to mark ("flag") an article for clarification/improvement. {{flag+link}} is memorable but the name seems to make it hard to find unless you know what you're looking for. Maybe we could consider renaming either or both of these templates? Thanks again for all the information! Facts707 (talk) 21:26, 6 September 2015 (UTC)
To me "flag article" or the like doesn't seem any more helpful than "flag+link". Either name implies the link target can be changed freely, which is not the case. "flagprefix" or similar would get my vote, as it suggests more clearly what the template does, and what the difference with {{flag}} is. (Template talk:Flag+link is a better place for a move request though.) SiBr4 (talk) 18:11, 7 September 2015 (UTC)

Zambia 1964 broken?

Zambia (1964) should have a darker shade of green than Zambia (current). It looks like it's set correctly in Zambia's Country data template, but it's not coming out right for some reason. Can someone fix this? If the dash in the file name is the problem, use Old Flag of Zambia.svg (which redirects to the same old flag). —Sygmoral (talk) 02:25, 18 November 2015 (UTC)

Fixed—variants don't work without this line. SiBr4 (talk) 07:41, 18 November 2015 (UTC)

Broken flags

Hi, the flags of  Jamaica,  Colombia,  Guinea-Bissau don't work currently. How to restore them? Wykx (talk) 21:18, 11 April 2017 (UTC)

It works again... Wykx (talk) 12:53, 12 April 2017 (UTC)

Bolivia flag

 Bolivia

The Bolivian flag doesn't include the coat of arms. Is this deliberate?Terrorist96 (talk) 03:45, 5 May 2017 (UTC)

ASEAN

Hi. I noticed in ASEAN–European Union relations that the flag of the Association of Southeast Asian Nations does not work in Template:Flag, Template:Flagicon as well as in Template:Infobox bilateral relations. It would be nice if it can be fixed by someone. Have a great day!--Concus Cretus (talk) 12:50, 23 May 2017 (UTC)

If you're referring to File:Flag of ASEAN.svg, then that file should not be added to templates. It's licensed as non-free content and therefore cannot be used in templates per WP:NFCC#9. -- Marchjuly (talk) 23:05, 23 May 2017 (UTC)

Crimea

 Crimea

The {{Flag|Crimea}} template gives a link to the Autonomous Republic of Crimea article, a clear violation of WP:NPOV. It should link to the Crimea article instead. Chessrat (talk, contributions) 00:24, 6 August 2017 (UTC)


Range and not arbitrary year

Would it be possible to have a "range" or "year range" variable which can be dynamically used to pick the right flag, based on the current year relevant to an article? For example, if you write an article covering a certain year (for example an event, a battle), and use that year in the {{flag}} template, would be great to get the correct flag from that year automatically. As in here:

  • {{flagicon|Germany|1870}}Germany
  • {{flagicon|Germany|1918}}Germany
  • {{flagicon|Germany|1919}}Germany
  • {{flagicon|Germany|1920}}Germany

Among many things, it would make it is possible to dynamically display the correct flags of the period, in articles like List of sovereign states in 1919. Codrin.B (talk) 14:03, 2 September 2017 (UTC)