Difference between revisions of "Template:Flag"

From IntactiWiki
Jump to navigation Jump to search
m
m (temporarily using simple mode)
 
(25 intermediate revisions by the same user not shown)
Line 1: Line 1:
[[File:{{Flag data {{{1}}}}}|30px|{{{1}}}]] {{{1}}}
+
<includeonly>{{{1}}}</includeonly><noinclude>
 +
This template creates a File link to a country flag, formatted in 25x15 pixels so far. If the related '''Template:Flag data <countryname>''' doesn't exist or is empty, just the country name is output.
 +
 
 +
'''Note:''' For the moment, we have switched off the creation and output of flags in favor of speed. It seems as if the flags aren't cached and have to be retrieved each time from the Wikipedia server. Chances are that we can speed up things when we add those files to our IntactiWiki pool somewhen in the future.
 +
 
 +
The working code of the original template:
 +
<pre>{{#ifexist: Template:Flag data {{{1}}}|[[File:{{Flag data {{{1}}}}}|25x15px|{{{1}}}]]&nbsp;{{{1}}}|{{{1}}} }}</pre>
 +
 
 +
{{Flag|Australia}}
 +
</noinclude>

Latest revision as of 12:51, 20 April 2021

This template creates a File link to a country flag, formatted in 25x15 pixels so far. If the related Template:Flag data <countryname> doesn't exist or is empty, just the country name is output.

Note: For the moment, we have switched off the creation and output of flags in favor of speed. It seems as if the flags aren't cached and have to be retrieved each time from the Wikipedia server. Chances are that we can speed up things when we add those files to our IntactiWiki pool somewhen in the future.

The working code of the original template:

{{#ifexist: Template:Flag data {{{1}}}|[[File:{{Flag data {{{1}}}}}|25x15px|{{{1}}}]] {{{1}}}|{{{1}}} }}

Australia