Template:Navbox with columns/doc

This page will only parse completely when it is included in another page.
A navigation box that presents its content in columns. Originally intended to provide a relatively straightforward means to align links prefixed by flag icons, e.g. in templates offering links to country articles.
[h="2"] Basic syntax [/h]
Only required parameters and [i]colwidth[/i] included.
<pre style="overflow:auto;">
[template]Navbox with columns
|name = [template]subst:PAGENAME[/template]
|title =
|colwidth =
|col1 =
|col2 =
[/template]
</pre>
[div] style="line-height:1.35em; font-size:90%;" |
* See [wiki="wikipedia:Em (typography)"]Em (typography)[/wiki]. Using proportional units means the template should still be displayed correctly across a range of browser font-sizes. If [i]colwidth[/i] not specified, a default 10em is used.
[/div]
[h="2"] Parameters [/h]
Required parameters in [b]bold[/b]. Parameters marked with a cross[b]<sup>?</sup>[/b] are parameters in common with the sister templates [template]t|Navbox[/template] and [template]t|Navbox with collapsible groups[/template]. A much more complete description of those parameters is available at [template]t|Navbox[/template].
[h="3"]Setup parameters[/h]
[indent];name<sup>?</sup>[/indent]::The name of the template. The name of this template, for example, is "Navbox with columns".
[indent];state<sup>?</sup>[/indent]::Possible values are <code>collapsed</code>, <code>uncollapsed</code>, <code>plain</code>, <code>off</code>, and the default <code>autocollapse</code>. See [template]t|Navbox[/template] for more information.
[indent];[i]navbar[/i]<sup>?</sup>[/indent]::Possible values are <code>plain</code>, <code>off</code>, and the default value of blank. See [template]t|Navbox[/template] for more information.
[indent];[i]border[/i]<sup>?</sup>[/indent]::Possible values are <code>child</code>, <code>none</code>, and the default value of blank. Set to <code>child</code> if you wish to use the navbox inside of another navbox; with this option, the child navbox is borderless and fits snuggly inside of its parent navbox. The parent navbox may be the list area of [template]t|Navbox[/template], a columns of another [template]t|Navbox with columns[/template], or a section of [template]t|Navbox with collapsible groups[/template]. See [template]t|Navbox[/template] for more information and examples.
[h="3"]Basic data parameters[/h]
[indent];[b][i]title[/b][/i]<sup>?</sup>[/indent]::The title of the template, displayed centered in the titlebar at the top of the template.
[indent];[i]above[/i]<sup>?</sup>[/indent]::Text or other elements to appear above the columns.
[indent];[i]image[/i]<sup>?</sup>[/indent]::Image to the right of all of the columns.
[indent];[i]imageleft[/i]<sup>?</sup>[/indent]::Image to the left of all of the columns.
[indent];[i]below[/i]<sup>?</sup>[/indent]::Text or other elements to appear below the columns.
[h="3"]Style parameters[/h]
[indent];[i]bodystyle[/i]<sup>?</sup>[/indent]::CSS style/s to apply to the template's body (i.e. including space not used by columns)
[indent];[i]titlestyle[/i]<sup>?</sup>[/indent]::[wiki="Wikipedia:CSS"]CSS[/wiki] style/s to apply to titlebar; usually <code>background:[i]color[/i]</code> (background defaults to [wiki="wikipedia:Wikipedia:NavFrame"]NavHead[/wiki] default).
[indent];[i]abovestyle[/i]<sup>?</sup>[/indent]:;[i]belowstyle[/i]<sup>?</sup>
[indent]:CSS style/s to apply to the [i]above[/i] and [i]below[/i] parameters, respectively.[/indent]
[indent];[i]basestyle[/i]<sup>?</sup>[/indent]::CSS style/s to apply to the [i]title[/i], [i]above[/i], and [i]below[/i], parameters, all at the same time.
[indent];[i]imagestyle[/i]<sup>?</sup>[/indent]::CSS style/s to apply to the [i]image[/i] parameter.
[indent];[i]imageleftstyle[/i]<sup>?</sup>[/indent]::CSS style/s to apply to the [i]imageleft[/i] parameter
[indent];[i]colsstyle[/i][/indent]::CSS style/s to apply across all columns; if used, usually <code>background:[i]color[/i]</code> per [i]titlestyle[/i] above.
[indent];[i]oddcolstyle[/i][/indent]:;[i]evencolstyle[/i]
[indent]:CSS style/s to apply to all odd/even-numbered columns, respectively.[/indent]
[indent];[i]col<sub>n</sub>style[/i][/indent]::CSS style/s to apply to the n<sup>th</sup> column only.
[indent];[i]colheaderstyle[/i][/indent]::CSS style/s to apply to all column headers.
[indent];[i]col<sub>n</sub>headerstyle[/i][/indent]::CSS style/s to apply to the n<sup>th</sup> column header.
[indent];[i]col<sub>n</sub>footerstyle[/i][/indent]::CSS style/s to apply to the n<sup>th</sup> column footer cell.
[h="3"]Columns parameters[/h]
[indent];[i]colwidth[/i][/indent]::Width, preferably in a proportional unit such as '[wiki="wikipedia:Em (typography)"]em[/wiki]', or as a percentage, used for each column whose width not specified by [i]colNwidth[/i] below. Defaults to 10em. Examples:
[indent]::<code>colwidth = 15em</code>[/indent]:::<code>colwidth = 25%</code>
[indent];[i]fullwidth[/i][/indent]::If set to anything, then the total width of the columns are scaled linearly to make the sum of the widths 100%. A rather advanced parameter, this usually need not be used and should be left blank. If a colheader or colfooter is used, then fullwidth is used automatically. Example:
[indent]::<code>fullwidth = true</code>[/indent]
[indent];[i]padding[/i][/indent]::Padding before first column, preferably in a proportional unit. Defaults to 5em. Padding is disabled by setting it to 0 (or 0em, or 0%).
[indent];[i]col<sub>n</sub>width[/i][/indent]::The n<sup>th</sup> column's width (overrides [i]colwidth[/i] above).
[indent];[b][i]col<sub>n</sub>[/b][/i][/indent]::The content of the n<sup>th</sup> column. <code>col1</code> is required. There can be a maximum of 20 columns.
[indent];[i]col<sub>n</sub>header[/i][/indent]::A header cell for the n<sup>th</sup> column that appears above the column. See below for examples.
[indent];''col<sub>n</sub>footer[/indent]::A footer cell that appears below the n<sup>th</sup> column.
[indent];''col<sub>n</sub>headercolspan[/indent]::A number specifying how many columns the n<sup>th</sup> column header should span. It defaults to 1. If it is greater than one, then do not specify column headers that it covers. For example, if <code>col1headercolspan = 3</code>, then leave <code>col2header</code> and <code>col3header</code> blank.
[indent];''col<sub>n</sub>footercolspan[/indent]::A number specifying how many columns the n<sup>th</sup> column footer should span. It defaults to 1. If it is greater than one, then do not specify column footers that it covers. For example, if <code>col1footercolspan = 3</code>, then leave <code>col2footer</code> and <code>col3footer</code> blank.
[h="3"]Additional lists[/h]
You may wish to add a few extra lists below the columns. The following parameters are given to provide such functionality. See [template]t|Navbox[/template] for a more complete description of how they work, and for more examples. Groups are not allowed.
[indent];[i]list<sub>n</sub>[/i]<sup>?</sup>[/indent]::Allows up to 6 additional lists below the columns.
[indent];[i]liststyle[/i]<sup>?</sup>[/indent]::The general CSS style/s for the lists.
[indent];[i]list<sub>n</sub>style[/i]<sup>?</sup>[/indent]::CSS style/s for the n<sup>th</sup> list parameter.
[indent];[i]listpadding[/i]<sup>?</sup>[/indent]::Amount of padding to have in each list cell.
[h="2"] Examples [/h]
===Basic example===
<pre style="overflow:scroll;">
[template]Navbox with columns
|name = East Asia Summit (EAS)
|title = Member states of the [wiki="East Asia Summit"]East Asia Summit (EAS)[/wiki]
|width = 18.25em
|padding = 10em
|above = [i]This is where the &#123;&#123;&#123;above&#125;&#125;&#125; would appear.[/i]
|col1 = [template]AUS[/template]<br/> [template]BRU[/template]<br/> [template]CAM[/template]<br/> [template]IND[/template]
|col2 = [template]IDN[/template]<br/> [template]JPN[/template]<br/> [template]LAO[/template]<br/> [template]MAS[/template]
|col3 = [template]MYA[/template]<br/> [template]NZL[/template]<br/> [template]CHN-PRC[/template]<br/> [template]PHI[/template]
|col4width=17em
|col4 = [template]SIN[/template]<br/> [template]KOR[/template]<br/> [template]THA[/template]<br/> [template]VIE[/template]
|below = [b]Potential future members[/b][template]spaces|6[/template][template]TLS[/template][template]spaces|3[/template][template]RUS[/template]
[/template]
</pre>
[template]Navbox with columns
|name = East Asia Summit (EAS)
|state = uncollapsed
|title = Member states of the [wiki="East Asia Summit"]East Asia Summit (EAS)[/wiki]
|width = 18.25em
|padding = 10em
|above = [i]This is where the &#123;&#123;&#123;above&#125;&#125;&#125; parameter would appear.[/i]
|col1 = [template]AUS[/template]<br/> [template]BRU[/template]<br/> [template]CAM[/template]<br/> [template]IND[/template]
|col2 = [template]IDN[/template]<br/> [template]JPN[/template]<br/> [template]LAO[/template]<br/> [template]MAS[/template]
|col3 = [template]MYA[/template]<br/> [template]NZL[/template]<br/> [template]CHN-PRC[/template]<br/> [template]PHI[/template]
|col4width=17em
|col4 = [template]SIN[/template]<br/> [template]KOR[/template]<br/> [template]THA[/template]<br/> [template]VIE[/template]
|below = [b]Potential future members[/b][template]spaces|6[/template][template]TLS[/template][template]spaces|3[/template][template]RUS[/template]
[/template]
[h="3"]Example with percentage widths[/h]
<pre style="overflow:scroll;">
[template]Navbox with columns
| name = Plastics
| title = [wiki]Plastic[/wiki]s
| colwidth = 33%
| colstyle = text-align: center
| col1 = [wiki]Polyethylene[/wiki] (PE)<br />[wiki]Polyethylene terephthalate[/wiki] (PET or PETE)<br />[wiki]Polyvinyl chloride[/wiki] (PVC)<br />[wiki]Polyvinylidene chloride[/wiki] (PVDC)<br />[wiki]Polylactic acid[/wiki] (PLA)
| col2 = [wiki]Polypropylene[/wiki] (PP)<br />[wiki]Polyamide[/wiki] (PA)<br />[wiki]Polycarbonate[/wiki] (PC)<br />[wiki]Polytetrafluoroethylene[/wiki] (PTFE)<br />[wiki]Polyurethane[/wiki] (PU)
| col3 = [wiki]Polystyrene[/wiki] (PS)<br /> [wiki]Polyester[/wiki]<br /> [wiki]Acrylonitrile butadiene styrene[/wiki] (ABS)<br /> [wiki="Acrylic glass"]Polymethyl methacrylate[/wiki] (PMMA)<br /> [wiki]Polyoxymethylene[/wiki] (POM)
[/template]
</pre>
[template]Navbox with columns
| name = Plastics
| title = [wiki]Plastic[/wiki]s
| state = uncollapsed
| cols = 3
| colwidth = 33%
| colstyle = text-align: center
| col1 = [wiki]Polyethylene[/wiki] (PE)<br />[wiki]Polyethylene terephthalate[/wiki] (PET or PETE)<br />[wiki]Polyvinyl chloride[/wiki] (PVC)<br />[wiki]Polyvinylidene chloride[/wiki] (PVDC)<br />[wiki]Polylactic acid[/wiki] (PLA)
| col2 = [wiki]Polypropylene[/wiki] (PP)<br />[wiki]Polyamide[/wiki] (PA)<br />[wiki]Polycarbonate[/wiki] (PC)<br />[wiki]Polytetrafluoroethylene[/wiki] (PTFE)<br />[wiki]Polyurethane[/wiki] (PU)
| col3 = [wiki]Polystyrene[/wiki] (PS)<br /> [wiki]Polyester[/wiki]<br /> [wiki]Acrylonitrile butadiene styrene[/wiki] (ABS)<br /> [wiki="Acrylic glass"]Polymethyl methacrylate[/wiki] (PMMA)<br /> [wiki]Polyoxymethylene[/wiki] (POM)
[/template]
[h="3"]Example with col<sub>n</sub>header and col<sub>n</sub>footer[/h]
The gray background for the columns is added for illustration only.
[template]Navbox with columns
|name = Navbox with columns/doc
|state = uncollapsed
|title = col<sub>n</sub>header and col<sub>n</sub>footer example
|colstyle = text-align:center;background:silver;
|colwidth = 25%
|col1header = col1header
|col2header = col2header
|col3header = col3header
|col4header = col4header
|col1 = col1
|col2 = col2
|col3 = col3
|col4 = col4
|col1footer = col1footer
|col2footer = col2footer
|col3footer = col3footer
|col4footer = col4footer
[/template]
[h="2"]Using child navboxes[/h]
All three types of navbox templates, namely [template]t|Navbox[/template], [template]t|Navbox with columns[/template], and [template]t|Navbox with collapsible groups[/template], can be nested inside of one another using the <code>border</code> parameter (which is common to all three). For complex templates, it may be necessary to use nesting to achieve a desired look.
[h="3"]Nesting Navbox with columns in itself[/h]
This example shows how one can nest multiple [template]t|Navbox with columns[/template] templates to get the right look. Edit this section to view the code. There is a main [template]t|Navbox with columns[/template] and two additional [template]t|Navbox with columns[/template] templates, with the "child" option set (see code).
[template]Navbox with columns
|name = Navbox with columns/doc
|state = uncollapsed
|title = Subgroups with nesting
|colstyle = text-align:center;background:silver;
|col1width = 33%
|col2width = 17%
|col3width = 33%
|col4width = 17%
|col1header = Col1Header
|col2header = Col2Header
|col3header = Col3Header
|col4header = Col4Header
|col1 = [template]Navbox with columns|child
|colwidth = 50%
|colstyle = text-align:center;background:silver;
|col1header = Col1.1Header
|col2header = Col1.2Header
|col1 = Col1.1
|col2 = Col1.2
[/template]
|col2 = Col2
|col3 = [template]Navbox with columns|child
|colwidth = 33%
|colstyle = text-align:center;background:silver;
|col1header = Col3.1Header
|col2header = Col3.2Header
|col3header = Col3.3Header
|col1 = Col3.1
|col2 = Col3.2
|col3 = Col3.3
[/template]
|col4 = Col4
[/template]
[h="3"]Nesting other Navbox forms[/h]
This example shows [template]t|Navbox[/template], [template]t|Navbox with collapsible groups[/template] and [template]t|Navbox with columns[/template] all working together. Press the edit button for the section to view the code. Note that each of the child navboxes has the first parameter set to <code>child</code>
[template]Navbox with collapsible groups
|name = Navbox with collapsible groups
|title = Navbox, Navbox with columns, and Navbox with collapsible groups together
|selected = {{{1|}}}
|group1 = [category=Scouting]The Scouting Movement[/category]
|abbr1 = movement
|list1 = [wiki]Scouting[/wiki][template]·[/template][i][wiki]Scouting for Boys[/wiki][/i][template]·[/template][wiki]Scout method[/wiki][template]·[/template][wiki]Scout Law[/wiki][template]·[/template][wiki]Scout Promise[/wiki][template]·[/template][wiki]Scout Motto[/wiki][template]·[/template][wiki]Wood Badge[/wiki][template]·[/template][wiki]Age groups in Scouting and Guiding[/wiki][template]·[/template][wiki]Cub Scout[/wiki][template]·[/template][wiki]Boy Scout[/wiki][template]·[/template][wiki]Rover Scout[/wiki][template]·[/template][wiki="Brownie (Girl Guides)"]Brownie[/wiki][template]·[/template][wiki]Girl Guiding and Girl Scouting[/wiki][template]·[/template][wiki]Ranger (Girl Guide)[/wiki][template]·[/template][wiki="Jamboree (Scouting)"]Jamboree[/wiki][template]·[/template][wiki]Scout Leader[/wiki][template]·[/template][wiki="World Organization of the Scout Movement"]WOSM[/wiki][template]·[/template][wiki="World Association of Girl Guides and Girl Scouts"]WAGGGS[/wiki][template]·[/template][wiki="Non-aligned Scouting and Scout-like organisations"]Non-aligned organisations[/wiki][template]·[/template][wiki]Scouting controversy and conflict[/wiki][template]·[/template][wiki]Scouting in popular culture[/wiki][template]·[/template][wiki]List of Scouts[/wiki][template]·[/template][wiki]List of highest awards in Scouting[/wiki]
|list2 = [template]Navbox|child
|title = [wiki="French colonial empires"]Former French colonies[/wiki] in [wiki]Africa[/wiki] and the [wiki]Indian Ocean[/wiki]
|titlestyle = background#
|groupstyle = background:lavender;
|group1 = [wiki]Mahgreb[/wiki]
|list1 = [wiki="French rule in Algeria"]Algeria[/wiki][template]·[/template] [wiki="French Morocco"]Morocco[/wiki]&nbsp;<small>([wiki="Arguin"]Arguin Island[/wiki])</small>[template]·[/template] [wiki="History of Tunisia"]Tunisia[/wiki]
|group2 = [wiki]French West Africa[/wiki]
|list2 = [wiki="History of Côte d'Ivoire#French Period"]Côte d'Ivoire[/wiki][template]·[/template] [wiki="French Dahomey"]Dahomey[/wiki][template]·[/template] [wiki]French Sudan[/wiki][template]·[/template] [wiki="French Guinea"]Guinea[/wiki][template]·[/template] [wiki="History of Mauritania#French colonization and post-colonial history"]Mauritania[/wiki][template]·[/template] [wiki="History of Niger#Colonization"]Niger[/wiki][template]·[/template] [wiki="History of Senegal"]Senegal[/wiki][template]·[/template] [wiki="French Upper Volta"]Upper Volta[/wiki]
|group3 = &nbsp;
|list3 = [wiki]French Togoland[/wiki][template]·[/template] [wiki="James Island (The Gambia)"]James Island[/wiki]
|group4 = [wiki]French Equatorial Africa[/wiki]
|list4 = [wiki="Colonial Chad"]Chad[/wiki][template]·[/template] [wiki="History of Gabon"]Gabon[/wiki][template]·[/template] [wiki="History of the Republic of the Congo"]Middle Congo[/wiki][template]·[/template] [wiki]Oubangui-Chari[/wiki]
|group5 = [wiki]Comoros[/wiki]
|list5 = [wiki]Anjouan[/wiki][template]·[/template] [wiki]Grande Comore[/wiki][template]·[/template] [wiki]Mohéli[/wiki]
|group6 = &nbsp;
|list6 = [wiki="History of Djibouti#French Interest"]French Somaliland (Djibouti)[/wiki][template]·[/template] [wiki="History of Madagascar#French Control"]Madagascar[/wiki][template]·[/template] [wiki="Mauritius"]Ile de France[/wiki][template]·[/template] [wiki]Seychelles[/wiki]
[/template]
|group3 = [category=Scouting in the United Kingdom]Scouting in the United Kingdom[/category]
|abbr3 = Scouting
|list3 = [wiki]The Scout Association[/wiki][template]·[/template][wiki]Girlguiding UK[/wiki][template]·[/template][wiki]Beaver Scouts[/wiki][template]·[/template][wiki]Cub Section (UK)[/wiki][template]·[/template][wiki]Venture Scout[/wiki][template]·[/template][wiki]Explorer Scouts[/wiki][template]·[/template][wiki]Brownie (Girl Guides)[/wiki][template]·[/template][wiki]Ranger (Girl Guide)[/wiki][template]·[/template][wiki]Rainbow (Girl Guides)[/wiki][template]·[/template][wiki]Scout Network[/wiki][template]·[/template][wiki]Chief Scout (United Kingdom)[/wiki][template]·[/template][wiki]Scout Counties[/wiki][template]·[/template][wiki]Scout District[/wiki][template]·[/template][wiki]Scout Section (UK)[/wiki][template]·[/template][wiki]Scout Activity Centre[/wiki][template]·[/template][wiki="Young Leaders (The Scout Association)"]Young Leaders[/wiki]
|list4 = [template]Navbox with columns|child
|title = Navbox with columns nested in itself
|colstyle = text-align:center;
|col1width = 33%
|col2width = 17%
|col3width = 33%
|col4width = 17%
|col1header = Col1Header
|col2header = Col2Header
|col3header = Col3Header
|col4header = Col4Header
|col1 = [template]Navbox with columns|child
|colwidth = 50%
|colstyle = text-align:center;
|col1header = Col1.1Header
|col2header = Col1.2Header
|col1 = Col1.1
|col2 = Col1.2
[/template]
|col2 = Col2
|col3 = [template]Navbox with columns|child
|colwidth = 33%
|colstyle = text-align:center;
|col1header = Col3.1Header
|col2header = Col3.2Header
|col3header = Col3.3Header
|col1 = Col3.1
|col2 = Col3.2
|col3 = Col3.3
[/template]
|col4 = Col4
[/template]
[/template]
[h="2"] See also [/h]
[list][*] [template]t|Navbox[/template] &ndash; Allows groups/lists instead of columns
[*] [template]t|Navbox with collapsible groups[/template] &ndash; Another variation.
[/LIST]

[top]Pages That Use This Template

The following pages include this template:


Tags for this Page

Similar Pages

  1. Navbox with columns
    By Arjan in forum Template
    Comments: 0
    Last Post: 12-05-2008, 01:19 PM
  2. Navbox
    By Arjan in forum Template
    Comments: 0
    Last Post: 12-05-2008, 11:51 AM

Bookmarks

Posting Permissions

Posting Permissions
  • You may not create new articles
  • You may not edit articles
  • You may not protect articles
  • You may not post comments
  • You may not post attachments
  • You may not edit your comments
BIRTHRIGHT, DUNGEONS & DRAGONS, D&D, the BIRTHRIGHT logo, and the D&D logo are trademarks owned by Wizards of the Coast, Inc., a subsidiary of Hasbro, Inc., and are used by permission. ©2002-2010 Wizards of the Coast, Inc.