3.2.0

i18n for numbers

I want my decimal numbers to appear with commas instead of periods for persons using my website on a Danish computer (ex. the number "7.859" should appear as "7,859"). Do I have to treat the number as a string, or is there a way to keep the value numeric and print commas instead of periods?

Thanks for any assistance.
Ben Alexander
February 21,
Of course, the only reason that the data type matters is sorting. If I represent numbers with quoted strings then I'm able to specify decimal numbers with commas instead of periods for Danish users, but then when someone clicks on a column header the numbers are sorted strangley. If there were a way to represent how the numbers should be ordered after sorting then I'd represent my numbers with quoted strings and be perfectly happy. Are there any alternative solutions along these lines?
Ben Alexander
February 21,
Ben,

There are many threads on this forum discussing formatting of numbers and sorting. If you do a quick search of the forum I think you are going to find many examples to show you how to overcome your issue.
Jim Hunter
February 21,

This topic is archived.

See also:


Back to support forum