Template:Infobox admin div: Difference between revisions

From OpenGeofiction
mNo edit summary
(+ list of five largest entities (cities, metro areas, etc.) now possible per user request)
Line 6: Line 6:
{{#if:{{{second-level|}}}|<tr {{#if:{{{third-level|}}}| class="cont" |}}><td><b>Second-level</b></td><td>{{{second-level|}}}</td></tr>|}}
{{#if:{{{second-level|}}}|<tr {{#if:{{{third-level|}}}| class="cont" |}}><td><b>Second-level</b></td><td>{{{second-level|}}}</td></tr>|}}
{{#if:{{{third-level|}}}|<tr {{#if:{{{fourth-level|}}}| class="cont" |}}><td><b>Third-level</b></td><td>{{{third-level|}}}</td></tr>|}}
{{#if:{{{third-level|}}}|<tr {{#if:{{{fourth-level|}}}| class="cont" |}}><td><b>Third-level</b></td><td>{{{third-level|}}}</td></tr>|}}
{{#if:{{{fourth-level|}}}|<tr><td><b>Fourth-level</b></td><td>{{{fourth-level|}}}</td></tr>|}}
{{#if:{{{fourth-level|}}}|<tr><td><b>Fourth-level</b></td><td>{{{fourth-level|}}}</td></tr>|}}<!--
-->{{#if:{{{div_type|}}}|<tr class="cont"><td colspan="2"><div style="background: #dddddd; text-align: center; padding: .1em;"><b>Largest {{{div_type|cities}}}</b></div></td></tr>
<tr><td>{{{div1|}}}<br />{{{div2|}}}{{#if:{{{div3|}}}|<br />{{{div3}}}|}}{{#if:{{{div4|}}}|<br />{{{div4}}}|}}{{#if:{{{div5|}}}|<br />{{{div5}}}|}}</td><td>{{{div1_pop|}}}<br />{{{div2_pop|}}}{{#if:{{{div3_pop|}}}|<br />{{{div3_pop}}}|}}{{#if:{{{div4_pop|}}}|<br />{{{div4_pop}}}|}}{{#if:{{{div5_pop|}}}|<br />{{{div5_pop}}}|}}</td></tr>|}}
</table>
</table>
</includeonly><noinclude>
</includeonly><noinclude>
Line 17: Line 19:
| third-level = (types of third-level divisions, if applicable)
| third-level = (types of third-level divisions, if applicable)
| fourth-level = (types of fourth-level divisions, if applicable)
| fourth-level = (types of fourth-level divisions, if applicable)
| div_type = (types of entities, e.g. cities or metropolitan areas, included in list of five largest; defaults to "cities")
| div1 = (name of largest political or administrative division)
| div2 = (name of second largest political or administrative division)
[...]
| div5 = (name of fifth largest political or administrative division)
| div1_pop = (population of largest political or administrative division)
| div2_pop = (population of second largest political or administrative division)
[...]
| div5_pop = (population of fifth largest political or administrative division)
}}
}}
</pre>
</pre>
[[Category:Infobox templates]]
[[Category:Infobox templates]]
</noinclude>
</noinclude>

Revision as of 19:00, 18 April 2024

This infobox is designed to highlight the types of administrative divisions in a territory. Provide an overview of information such as "6 provinces" in the first-level parameter instead of listing each province by name. Important: Please do not include a full listing of all administrative divisions, as this template is not designed for it. Consider constructing a table on your territory's administrative divisions page.

{{Infobox admin div
| name = (territory name)
| first-level = (types of first-level divisions; skip if a state of the Federal States)
| second-level = (types of second-level divisions, if applicable)
| third-level = (types of third-level divisions, if applicable)
| fourth-level = (types of fourth-level divisions, if applicable)
| div_type = (types of entities, e.g. cities or metropolitan areas, included in list of five largest; defaults to "cities")
| div1 = (name of largest political or administrative division)
| div2 = (name of second largest political or administrative division)
[...]
| div5 = (name of fifth largest political or administrative division)
| div1_pop = (population of largest political or administrative division)
| div2_pop = (population of second largest political or administrative division)
[...]
| div5_pop = (population of fifth largest political or administrative division)
}}