Template:Ordinalsup
Jump to navigation
Jump to search
Appends a superscripted ordinal suffix on a given input number
Parameters[edit]
The first parameter can be any string, as long as it ends with 1 or 2 digits it will assumed to be a number and converted to an ordinal.
Examples[edit]
| Code | Output | Notes |
|---|---|---|
| {{ordinalsup}} | null input | |
| {{ordinalsup|abc}} | abc | non-numeric input |
| {{ordinalsup|0}} | 0th | |
| {{ordinalsup|1}} | 1st | |
| {{ordinalsup|2}} | 2nd | |
| {{ordinalsup|3}} | 3rd | |
| {{ordinalsup|4}} | 4th | |
| {{ordinalsup|5}} | 5th | |
| {{ordinalsup|6}} | 6th | |
| {{ordinalsup|7}} | 7th | |
| {{ordinalsup|8}} | 8th | |
| {{ordinalsup|9}} | 9th | |
| {{ordinalsup|10}} | 10th | |
| {{ordinalsup|11}} | 11th | |
| {{ordinalsup|12}} | 12th | |
| {{ordinalsup|13}} | 13th | |
| {{ordinalsup|20}} | 20th | |
| {{ordinalsup|21}} | 21st | |
| {{ordinalsup|22}} | 22nd | |
| {{ordinalsup|23}} | 23rd | |
| {{ordinalsup|24}} | 24th |
See Also[edit]
- template:ordinal baselined version
- template:ordinalword worded version
- template:ordinalwordcap capitalized worded version