When i do
$("#sum").html(parseFloat("2.2").toFixed(2));
In firefox i get:
"<b xmlns="http://www.w3.org/1999/xhtml">2.20</b>"
in
$("#sum").html()
I want to calculate (and display correct) with this div (#sum) what is not possible, because i get the float value with
sum = parseFloat($("#summe").html());
and it returns NaN.
This works with Chrome. Is there any way to get this to work with firefox?
Use
.text()in both cases rather than.html(), since you are only setting text.