How can i format a number string using jQuery Number Plugin using "," as decimal delimiter

StackOverflow https://stackoverflow.com/questions/22858442

  •  27-06-2023
  •  | 
  •  

I use jQuery Number Plugin to format my percentage values to my desired format on a website. However, when i try to format the value 0.5 to look like 0,50 the value becomes 5,00.

The error seems to appear when I set the decimal delimiter to something other than .. Why is this?

Se fiddle for example

http://jsfiddle.net/9C828/2/

有帮助吗?

解决方案

Seems to be a known issue: https://github.com/teamdf/jquery-number/issues/43

I switched to use autoNumeric which seems to work good for my cause!

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top