Skip to main content
better answer
Source Link
IEnumerator
  • 3k
  • 5
  • 31
  • 34

checkI know you've found a solution to your question, I just wanted to recommend that maybe you look at the following functionmore extensive jQuery plugin for International Number Formats: Format Currency

Use it as: (123456789.12345).formatMoney(2, '.', ',');International Number Formatter

check the following function: Format Currency

Use it as: (123456789.12345).formatMoney(2, '.', ',');

I know you've found a solution to your question, I just wanted to recommend that maybe you look at the following more extensive jQuery plugin for International Number Formats:

International Number Formatter

issue with function
Source Link
IEnumerator
  • 3k
  • 5
  • 31
  • 34

maybe there is a better solution out there but off the top of my mind, removecheck the $ and comma then use parseFloatfollowing function: Format Currency

Use it as: (YOUR_NUMBER123456789.12345).formatMoney(2, '.', ',');

maybe there is a better solution out there but off the top of my mind, remove the $ and comma then use parseFloat(YOUR_NUMBER)

check the following function: Format Currency

Use it as: (123456789.12345).formatMoney(2, '.', ',');

Source Link
IEnumerator
  • 3k
  • 5
  • 31
  • 34

maybe there is a better solution out there but off the top of my mind, remove the $ and comma then use parseFloat(YOUR_NUMBER)