Template:Sort

From Killing Floor Wiki
Jump to: navigation, search

{{{1}}} [[{{{1}}}]]

[edit] [purge] Template-info.svg Template documentation

This template is for optionally sorting tables by specified sortkeys.

If necessary, one can apply sorting using a sortkey that due to CSS is not displayed: <span style="display:none">...</span>. JavaScript sorting is based on the text inside and outside the tags, without the tags themselves. A hidden sortkey can be put at the start.

This template makes that more convenient. The first parameter is the sortkey; the second parameter is the wikitext of what has to be displayed. By default, this is the sortkey with link brackets.

Usage[edit]

{{sort|Sort key|Text displayed}}

Sort key Text displayed

Example[edit]

{| class="wikitable sortable"
|-
! Heading
|-
| A
|-
| {{sort|B|The B}}
|-
| C
|}
Heading
A
B The B
C