Welcome To Snipplr


Everyone's Recent JavaScript Snippets Tagged number



« Prev 1 Next »
Add / Remove comma for number in the thousands. Ex: 1,000 Useful for grabbing input values to format then display, remove the comma and convert back to number to do math.
0 1687 posted 10 years ago by supawaza
A quick function that makes it easy to convert an integer into a number string with commas inserted.
0 817 posted 11 years ago by uberdragon
Generic function - Pass the context to the function for use with any field
0 819 posted 11 years ago by chetkloss
format numbers in javascript with group digits
0 1281 posted 12 years ago by rg443
Write a given number in words - Escreve um número por extenso. Write in Brazilian Portuguese, sorry for english or other language guys but it can be adapted. Write from 1 to 9999 Based on a forum in http://scriptbrasil.com.br/forum/index.php?...
0 1234 posted 12 years ago by glauberportella
By not being limited to provide certain arguments/parameters in right order when calling a function, makes the function more versatile and easier to extend without breaking old code (e.g. calls to the function). One solution is to pass an associati...
0 988 posted 12 years ago by coprolit
Thanks to http://www.mredkj.com/javascript/numberFormat.html#addcommas
0 692 posted 13 years ago by fengelz
it parses given string and returns 1st number it encounters ( it will replace comas with dots so floats formatted as 12,345 could be 12.345 ( some countries use that ) ) then u can parse returned value as a number / float / int - do what You need...
0 887 posted 14 years ago by stryju
Simple function to return a decimal value between the minValue and the maxValue.
0 1703 posted 14 years ago by Jamie
Simple function to return a value between the minValue and the maxValue.
0 805 posted 14 years ago by Jamie
converts a number "v" to a float number and formats the string it with "d" decimals, used on input type text onblur="parseFloatString(this.value,2);"
0 1023 posted 15 years ago by ginoplusio
The Number objects value determines how often the supplied function is repeated. Inspired by ROR & Python. "Pollutes" Number's prototype.
0 754 posted 15 years ago by peta
first of all i thank to our Creator and Mr.ImHugo for his Action script which i make the java script from it,its works fine and once again i gives thank him for his snippet
1 765 posted 15 years ago by sujithfem
to use this function send in an ASCII character code (use my getKeyCode function) it will return true if the code corresponds to a printable character (not backspace code - 8, enter code - 13, or "undefined")
0 635 posted 15 years ago by jlvallelonga
a set of function useful to check data (functions name in italian but easy to translate).
0 1018 posted 15 years ago by ginoplusio
Convert a number to a different base.
0 836 posted 16 years ago by wizard04
Adds commas to numbers. 1234567 becomes 1,234,567
1 1029 posted 16 years ago by jdstraughan
« Prev 1 Next »