w2ui
Home
Get started
Demos
Docs
Blog
Support
Layout
Grid
Toolbar
Sidebar
Tabs
Form
Popup
Utilities
ver 1.3
ver 1.4
ver 1.5
ver 2.0
Utilities
Overview
Properties
Methods
Other
Events
Keyboard
Plugins
w2utils.formatNumber
Formats a number adding commas.
w2utils.formatNumber(val)
val
string
or
number
, a number to format
The
val
argument can be an integer, float on in money format. The method will add commas after each there digits
var a = w2utils.formatNumber('$1234095.04'); console.log(a);
User Comments
Please enable JavaScript to view the
comments powered by Disqus.
comments powered by
Disqus