Hi, thanks for replying. I've made some changes to my code. I'm able to calc the product total and grand total, but thats only for one row. Therefore, if I insert another row, it does not do the calc product or grand total function.
Code:
<?
mysql_connect("", "", "");
mysql_select_db(invoice);
session_start();
?>
<!DOCTYPE html PUBLIC
Invoice form: calculate grand total of products and add rows
Hi, I'm trying to create a Invoice form with javascript. Basically, my invoice form should have the field item, cost, quantity and product total.
It shd have a function to allow the user to add rows if they want more than one item.
In the end, there should be a sub total. I am able to use javascript to calc the total of each product, but not all products(Grand total). I am also unable to add rows.
Leave a comment: