I have the following problem with IE when making calculations with floating-point numbers.
For instance, I have a div, which width is 150px and length 150px. I am subtracting say 15.787754565454 64 from its width.
All major browsers return 134.21224543454 537 px, but IE returns 134.21. Internet Explorer removes all the decimals, but the first TWO.
I'm using IE 10.
Is there a way to return all decimals in IE?
For instance, I have a div, which width is 150px and length 150px. I am subtracting say 15.787754565454 64 from its width.
Code:
div.style.width = (parseFloat(div.style.width) - 15.78775456545464) + "px";
I'm using IE 10.
Is there a way to return all decimals in IE?
Comment