Difference between revisions of "Template:Historical currencies of a country"

From blackwiki
Jump to navigation Jump to search
imported>Frietjes
imported>Pppery
(Prune code duplication)
 
Line 7: Line 7:
 
   <tr>
 
   <tr>
 
   <td>{{{1}}}</td>
 
   <td>{{{1}}}</td>
  <td style="border-left:1px #aaa solid;">{{{2}}}</td><!--
+
{{for nowiki||<nowiki>{{#if:{{{1}}}|{{#tag:td|{{{1}}}|style="border-left:1px #aaa solid;"}}}}</nowiki>|{{{2}}}|{{{3|}}}|{{{4|}}}|{{{5|}}}|{{{6|}}}|{{{7|}}}|{{{8|}}}|{{{9|}}}|{{{10|}}}|{{{11|}}}|{{{12|}}}|{{{13|}}}|{{{14|}}}|{{{15|}}}}}
    -->{{#if:{{{3|}}} |<td style="border-left:1px #aaa solid;">{{{3}}}</td>}}<!--
 
    -->{{#if:{{{4|}}} |<td style="border-left:1px #aaa solid;">{{{4}}}</td>}}<!--
 
    -->{{#if:{{{5|}}} |<td style="border-left:1px #aaa solid;">{{{5}}}</td>}}<!--
 
    -->{{#if:{{{6|}}} |<td style="border-left:1px #aaa solid;">{{{6}}}</td>}}<!--
 
    -->{{#if:{{{7|}}} |<td style="border-left:1px #aaa solid;">{{{7}}}</td>}}<!--
 
    -->{{#if:{{{8|}}} |<td style="border-left:1px #aaa solid;">{{{8}}}</td>}}<!--
 
    -->{{#if:{{{9|}}} |<td style="border-left:1px #aaa solid;">{{{9}}}</td>}}<!--
 
    -->{{#if:{{{10|}}} |<td style="border-left:1px #aaa solid;">{{{10}}}</td>}}<!--
 
    -->{{#if:{{{11|}}} |<td style="border-left:1px #aaa solid;">{{{11}}}</td>}}<!--
 
    -->{{#if:{{{12|}}} |<td style="border-left:1px #aaa solid;">{{{12}}}</td>}}<!--
 
    -->{{#if:{{{13|}}} |<td style="border-left:1px #aaa solid;">{{{13}}}</td>}}<!--
 
    -->{{#if:{{{14|}}} |<td style="border-left:1px #aaa solid;">{{{14}}}</td>}}<!--
 
    -->{{#if:{{{15|}}} |<td style="border-left:1px #aaa solid;">{{{15}}}</td>}}
 
 
   </tr>
 
   </tr>
 
  </table>
 
  </table>

Latest revision as of 21:45, 21 September 2017

Template documentation

This is the root template for all templates that follow the format "Historical currencies of a country", where a country is a country/territory. See templates on What links here for real example.

Instructions

Parameters:

  • country: The country. Format appropriate wiki link such as "the [[Netherlands]]", "the [[United Kingdom|U.K.]]
  • flag_image: File name of the flag. Do not include "Image".
  • flag_image_alt: The alternative image tag when mouse over.
  • my_name: Name of the template that transcludes this.
  • state: See above
  • The rest is the list of currencies to be displayed. The following style is recommended
  • [[Actual article name (no redirect)|currency name without the national adjective]]<br/>start year-end year
  • Normally, the end year of a period is the start year of the next, unless the end date is December 31 of a year.
  • It is recommended to make a navigational box if there are 5 or more articles. This template only supports up to 15 articles.

Collapsed state

Initial visibility: currently defaults to expanded

To set this template's initial visibility, the |state= parameter may be used:

  • |state=collapsed: {{Historical currencies of a country|state=collapsed}} to show the template collapsed, i.e., hidden apart from its title bar
  • |state=expanded: {{Historical currencies of a country|state=expanded}} to show the template expanded, i.e., fully visible
  • |state=autocollapse: {{Historical currencies of a country|state=autocollapse}}
    • shows the template collapsed to the title bar if there is a {{navbar}}, a {{sidebar}}, or some other table on the page with the collapsible attribute
    • shows the template in its expanded state if there are no other collapsible items on the page

If the |state= parameter in the template on this page is not set, the template's initial visibility is taken from the |default= parameter in the Collapsible option template. For the template on this page, that currently evaluates to expanded.

Example code

Here is a copy (which could be a stale copy) of the code for Template:Historical currencies of Argentina:

{{Historical currencies of a country
|country = [[Argentina]]
|flag_image = Flag of Argentina.svg
|flag_image_alt = Flag of Argentina
|my_name = Historical currencies of Argentina
|[[Argentine real|Real]]<br/>1813–1881
|[[Argentine peso moneda nacional|Peso moneda nacional]]<br/>1881–1969
|[[Argentine peso ley|Peso ley]]<br/>1970–1983
|[[Argentine peso argentino|Peso argentino]]<br/>1983–1985
|[[Argentine austral|Austral]]<br/>1985–1991
|[[Argentine peso|Peso]]<br/>1992–''present''
}}

See also

Template:Numismatic navigational templates