Log in


From PathfinderWiki
Revision as of 05:09, 28 December 2018 by Oznogon (talk | contribs) (Categorize)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)


Template documentation (for the above template, sometimes hidden or invisible)


{{Sort}} is a utility template used to force a cell in a sortable table (one using the sortable class) to be sorted differently from its contents.


{{Sort|sort key}}

The template takes one unnamed parameter:

sort key
The text to use when sorting the table by this cell's column.


{| class="tantable sortable"
! Title
! Issue
| ''Dance of the Damned''
| {{Sort|099}} PF #99
| {{Sort|Song of Silver, A}} ''A Song of Silver''
| {{Sort|100}} PF #100
| {{Sort|Kintargo Contract, The}} ''The Kintargo Contract''
| {{Sort|101}} PF #101
results in
Title Issue
Dance of the Damned 099 PF #99
Song of Silver, A A Song of Silver 100 PF #100
Kintargo Contract, The The Kintargo Contract 101 PF #101

When clicking on the table header row to sort by column contents, note how the sort keys affect the resulting order.

Numbers are not sorted in truly numeric order; "10" is sorted before "9", because "1" comes before "9" in sorting order in the same sense that "Aroden" comes before "Zyphus". To correctly sort numbers, pad all numbers with enough leading zeroes for the sort key with the most digits ("09" comes before "10", "099" comes before "100", etc.).

Visit Template:Sort/doc to edit this text! (How does this work?)