An input element contains numbers a where comma or dot is used as decimal separator and space may be used to group thousands like this:
\'1,2\'
You could replace all spaces by an empty string, all comas by dots and then parse it.
var str = "110 000,23"; var num = parseFloat(str.replace(/\s/g, "").replace(",", ".")); console.log(num);
I used a regex in the first one to be able to match all spaces, not just the first one.