Template:ComCur: Difference between revisions

From Elanthipedia
Jump to navigation Jump to search
No edit summary
(duh)
Line 4: Line 4:
|{{#switch:{{#len:{{{1}}}}}
|{{#switch:{{#len:{{{1}}}}}
|1|2|3={{{1}}}
|1|2|3={{{1}}}
|4={{#sub:{{{1}}}|0|1}},{{{#sub{{{1}}}|1|3}}
|4={{#sub:{{{1}}}|0|1}},{{{#sub:{{{1}}}|1|3}}
|5={{#sub:{{{1}}}|0|2}},{{{#sub{{{1}}}|2|3}}
|5={{#sub:{{{1}}}|0|2}},{{{#sub:{{{1}}}|2|3}}
|6={{#sub:{{{1}}}|3|1}},{{{#sub{{{1}}}|3|3}}
|6={{#sub:{{{1}}}|3|1}},{{{#sub:{{{1}}}|3|3}}
|7={{#sub:{{{1}}}|0|1}},{{#sub:{{{1}}}|1|3}},{{#sub:{{{1}}}|4|3}}
|7={{#sub:{{{1}}}|0|1}},{{#sub:{{{1}}}|1|3}},{{#sub:{{{1}}}|4|3}}
|8={{#sub:{{{1}}}|0|2}},{{#sub:{{{1}}}|2|3}},{{#sub:{{{1}}}|5|3}}
|8={{#sub:{{{1}}}|0|2}},{{#sub:{{{1}}}|2|3}},{{#sub:{{{1}}}|5|3}}

Revision as of 14:23, 16 July 2013

This template will take a series of numbers and properly add commas. If it has any commas already, is more than 12 digits, or has a currency type, it will not make any changes.