Changes

Help:Tables

1 byte added, 02:41, 8 April 2007
Moving Classes section closer to the top - more relevant for most editors, I think.
 
:''Careful'': You '''must include''' the '''space''' between <code>'''{|'''</code> and <code>''params''</code>, or the first parameter gets ignored.
 
==Classes==
The CSS files on UESP provide several pre-formatted classes to make various tables. These are a quick way to get nice looking tables without needing to learn what all those other features do. The most commonly used ones are "wikitable", "greylapse", and "toc". In order to use them, add the parameter <code>class='''class'''</code> after the <code>{|</code> line in the chart. Examples:
 
{|
|-valign=top
|
<nowiki>{|</nowiki>
<nowiki>!Header 1!!Header 2</nowiki>
<nowiki>|-</nowiki>
<nowiki>|abcde||fghij</nowiki>
<nowiki>|-</nowiki>
<nowiki>|klmno||pqrst</nowiki>
<nowiki>|}</nowiki>
|
<nowiki>{| class=wikitable</nowiki>
<nowiki>!Header 1!!Header 2</nowiki>
<nowiki>|-</nowiki>
<nowiki>|abcde||fghij</nowiki>
<nowiki>|-</nowiki>
<nowiki>|klmno||pqrst</nowiki>
<nowiki>|}</nowiki>
|
<nowiki>{| class=greylapse</nowiki>
<nowiki>!Header 1!!Header 2</nowiki>
<nowiki>|-</nowiki>
<nowiki>|abcde||fghij</nowiki>
<nowiki>|-</nowiki>
<nowiki>|klmno||pqrst</nowiki>
<nowiki>|}</nowiki>
|
<nowiki>{| class=toc</nowiki>
<nowiki>!Header 1!!Header 2</nowiki>
<nowiki>|-</nowiki>
<nowiki>|abcde||fghij</nowiki>
<nowiki>|-</nowiki>
<nowiki>|klmno||pqrst</nowiki>
<nowiki>|}</nowiki>
|-
|
{|
!Header 1!!Header 2
|-
|abcde||fghij
|-
|klmno||pqrst
|}
|
{| class=wikitable
!Header 1!!Header 2
|-
|abcde||fghij
|-
|klmno||pqrst
|}
|
{| class=greylapse
!Header 1!!Header 2
|-
|abcde||fghij
|-
|klmno||pqrst
|}
|
{| class=toc
!Header 1!!Header 2
|-
|abcde||fghij
|-
|klmno||pqrst
|}
|}
The "wikitable" clsss is generally the preferred format for most charts, though "greylapse" is also acceptable in cases where space is a premium, as it uses slightly less space. The "toc" class is usually reserved for creating a custom Table of Contents on pages where the default Table of Contents is not wanted.
 
==TD==
! RH 3 || ||
|}
==Classes==
The CSS files on UESP provide several pre-formatted classes to make various tables. These are a quick way to get nice looking tables without needing to learn what all those other features do. The most commonly used ones are "wikitable", "greylapse", and "toc". In order to use them, add the parameter <code>class='''class'''</code> after the <code>{|</code> line in the chart. Examples:
 
{|
|-valign=top
|
<nowiki>{|</nowiki>
<nowiki>!Header 1!!Header 2</nowiki>
<nowiki>|-</nowiki>
<nowiki>|abcde||fghij</nowiki>
<nowiki>|-</nowiki>
<nowiki>|klmno||pqrst</nowiki>
<nowiki>|}</nowiki>
|
<nowiki>{| class=wikitable</nowiki>
<nowiki>!Header 1!!Header 2</nowiki>
<nowiki>|-</nowiki>
<nowiki>|abcde||fghij</nowiki>
<nowiki>|-</nowiki>
<nowiki>|klmno||pqrst</nowiki>
<nowiki>|}</nowiki>
|
<nowiki>{| class=greylapse</nowiki>
<nowiki>!Header 1!!Header 2</nowiki>
<nowiki>|-</nowiki>
<nowiki>|abcde||fghij</nowiki>
<nowiki>|-</nowiki>
<nowiki>|klmno||pqrst</nowiki>
<nowiki>|}</nowiki>
|
<nowiki>{| class=toc</nowiki>
<nowiki>!Header 1!!Header 2</nowiki>
<nowiki>|-</nowiki>
<nowiki>|abcde||fghij</nowiki>
<nowiki>|-</nowiki>
<nowiki>|klmno||pqrst</nowiki>
<nowiki>|}</nowiki>
|-
|
{|
!Header 1!!Header 2
|-
|abcde||fghij
|-
|klmno||pqrst
|}
|
{| class=wikitable
!Header 1!!Header 2
|-
|abcde||fghij
|-
|klmno||pqrst
|}
|
{| class=greylapse
!Header 1!!Header 2
|-
|abcde||fghij
|-
|klmno||pqrst
|}
|
{| class=toc
!Header 1!!Header 2
|-
|abcde||fghij
|-
|klmno||pqrst
|}
|}
The "wikitable" clsss is generally the preferred format for most charts, though "greylapse" is also acceptable in cases where space is a premium, as it uses slightly less space. The "toc" class is usually reserved for creating a custom Table of Contents on pages where the default Table of Contents is not wanted.