Hello everyone,
I have the following code:
<html>
<body>
<script type="text/javascript">
var result=Math.round(10.10123*100)/100 //returns 10.1
alert(result)
</script>
</body>
</html>
This script alerts 10.1 and not 10.10
Is there anyway to make it so that it rounds to two decimal places all the time?
TYI


Reply With Quote
Bookmarks