...

need to keep trailing zeros, Fixed(2) not working

pell
10-09-2008, 11:49 PM
Posted this earlier and got a response, but it won't work. I am really stuck and hope someone can help.

Have an order form: each row contains quantity (input), base price (constant), tax (constant), subtotal. Here is the math code:

for (var p in output_data) {$('#'+p).html(Math.round(output_data[p]*100)/100);}

The response I got was to tag on .toFixed(2) so here's what I did:
for (var p in output_data) {('#'+p).html(Math.round(output_data[p]*100)/100).toFixed(2);}

The tax is showing up in the subtotal column and I'm losing trailing zeros. Here's the page: http://www.interactivesystems.biz/is/tvplay.php

user=is
pass=michael11

(folder is pass protected). I would really appreciate some assistance with this, hope you can hellp.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum