dreaogse 0 Newbie Poster

I have been searching for days looking for a good way to solve my code problem.

I have a PHP page that is dynamically creating a form with textboxes and checkboxes. The textbox has a quantity to order of an item and the checkbox is add item to order.
The user is to check the boxes of items he/she wants to order and then press the "Add to shopping cart" button below.

Problem 1: I can't use the Value field because it's set with formatted data for the chopping cart server (off site service).
Possible solution is to build an array with the data and/or feed the data direct from variables available via PHP server, but how.

What I need is for the "Subtotal" to update every time the user changes a checkbox and/or quantity in the textbox.

I am, as usual, VERY new to Javascript and also new but learning PHP. The PHP side is working wonderfully and I have currently a bit of code that is updating the checkbox side that I found on another web page:
http://www.dynamicsitesolutions.com/javascript/using-checkboxes-to-update-total/
But, again, it only updates the total with the change to the checkbox and I need something that will update with a change to both.

I have included the .js code and the PHP page in this post

Thanks