Template:Digits
Appearance
| Template documentation follows |
|---|
| Note: the template above may sometimes be partially or fully invisible. |
| Visit "Template:Digits/doc" to edit its documentation if it is available. (How does this work?) |
| This template is used on approximately 6,500 pages and changes may be widely noticed. Test changes in the template's /sandbox or /testcases subpages, or in your own user subpage. Consider discussing changes on the talk page before implementing them. |
Lua error in Module:Lua_banner at line 115: attempt to compare nil with number.
Usage
{{digits|string}}
{{digits|1=string}}
Removes all characters from string that are not a digit 0–9.
Examples
{{digits|12px}}→ 12
{{digits|1,234,567}}→ 1234567
{{digits|$1.23}}→ 123
{{digits|1=1+2=3}}→ 123
{{digits|24.51 km (15.23 mi)}}→ 24511523
See also
- {{str number/trim}}, remove the first non-digit character and everything following
- {{cardinal}}, remove ordinal indicators, eg.
{{cardinal|1st}}→ 1
Lua error in Module:Navbox_with_collapsible_groups at line 6: attempt to call field 'with collapsible groups' (a nil value).