Possible Duplicate:
How to avoid scientific notation for large numbers in javascript? Javascript: how to avoid scientific notation when displaying large unumber
I have this code:
var f = 1000000000000000000000; // 1e+21
var fstr = f.toString(); // return "1e+21"
But I don't need scientific number representa开发者_运维百科tion. I want to get "1000000000000000000000" in 'fstr' variable. How I can get it?
You can find an util script here:
http://snippets.dzone.com/posts/show/2206
There is also a short example at the bottom of the page.
精彩评论