New issue 1797 by hussain...@gmail.com: Chrome - toLocaleString() function
is not converting the number into local format.
http://code.google.com/p/v8/issues/detail?id=1797
toLocaleString() function is not converting the number into local format.
actually website will convert the numbers automatically.
eg:
india : 1,00,000.00
Germany : 1.00.000,00
please check the attachment for more details.
Attachments:
issue Chrome.jpg 273 KB
jsLocaleString.htm 240 bytes
Comment #1 on issue 1797 by yan...@chromium.org: Chrome - toLocaleString()
function is not converting the number into local format.
http://code.google.com/p/v8/issues/detail?id=1797
The ES5 spec says:
"Produces a String value that represents this Number value formatted
according to the conventions of the host environment's current locale. This
function is implementation-dependent, and it is permissible, but not
encouraged, for it to return the same thing as toString."
While v8 does not offer the best solution right now, the current behavior
*is* ES5 conform.
Is there a suggested work around until the best solution is offered? Will
this be resolved in the future?
In the short term there are no plans to change this as long as its spec
conform. However, I can't say that this will stay this way in the long term.
For a work around I would suggest one of the widely available frameworks
such as http://www.datejs.com/