Hi.<br>
<br>
I'm writing an ecomm programme using Javascript. The problem is, the total amount shows up as 59.9 instead of 59.90. How do I force it to show two decimal places?<br>
<br>
cost += Math.floor(items<i>.price * items<i>.qty * 100)/100;<br>
write("<TD>" + totalcost);<br>
<br>
Thanks,<br>
<br>
I'm writing an ecomm programme using Javascript. The problem is, the total amount shows up as 59.9 instead of 59.90. How do I force it to show two decimal places?<br>
<br>
cost += Math.floor(items<i>.price * items<i>.qty * 100)/100;<br>
write("<TD>" + totalcost);<br>
<br>
Thanks,<br>