Jump to content

Template:Country population: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
let's try this…
use {{first word}} because section transclusion may return more than the population
Line 1: Line 1:
<includeonly>{{trim | {{#ifexist: {{data {{{1}}} }}
<includeonly>{{trim | {{#ifexist: {{data {{{1}}} }}
| {{Template:data {{{1}}}|poptoday|formatnum}}
| {{data {{{1}}}|poptoday|formatnum}}
| {{#section:List of countries and dependencies by population | {{{1}}} }} }} }}</includeonly><noinclude>
| {{first word|{{#section:List of countries and dependencies by population | {{{1}}} }} n/a}} }} }}</includeonly><noinclude>
{{Documentation|content=
{{Documentation|content=
Template for referencing a country's (or territory's) population at [[List of countries and dependencies by population]].
Template for referencing a country's (or territory's) population at [[List of countries and dependencies by population]].
Line 7: Line 7:
=== Usage ===
=== Usage ===
<code><nowiki>{{Country population | country name}}</nowiki></code>
<code><nowiki>{{Country population | country name}}</nowiki></code>
=== Example ===
=== Examples ===
<code><nowiki>{{Country population | China}}</nowiki></code> produces: {{Country population | China}}

<code><nowiki>{{Country population | Indonesia}}</nowiki></code> produces: {{Country population | Indonesia}}
<code><nowiki>{{Country population | Indonesia}}</nowiki></code> produces: {{Country population | Indonesia}}
}}</noinclude>
}}</noinclude>

Revision as of 10:36, 25 October 2019