budapestnori
Technical User
I have a web page that I have taken as far as I can. Can someone show me how to accomplish what is what I am obviously trying to do on this page:
You will see each image has a spot for current Image Total. This figure will need to be able to be changed up or down dynamically. It would also be nice at page top to have a cumulitatve total.
I would think that to do this, I might pass the js func an id number, such as 234 to be used as an indice for the each images form fields total value name. As in 234_tot_cost, 435_tot_cost, 4323_tot_cost. Then, as with each onChange, either add or subtract that amount from the total. But how do I disern if the total is to be increased or descreased? Say they chose 2 8x10's, and 5 4x6's. The total will be "x". But then they go back and change the number of 4x6's to 3. The only way I can think to address this is to each time assign the value of the sum values for each form element for that image. In other words, every time an onChange activates the func, cycle through each of the other 5 elements pertinent to that image, resulting in a new total... Am I warm?
You will see each image has a spot for current Image Total. This figure will need to be able to be changed up or down dynamically. It would also be nice at page top to have a cumulitatve total.
I would think that to do this, I might pass the js func an id number, such as 234 to be used as an indice for the each images form fields total value name. As in 234_tot_cost, 435_tot_cost, 4323_tot_cost. Then, as with each onChange, either add or subtract that amount from the total. But how do I disern if the total is to be increased or descreased? Say they chose 2 8x10's, and 5 4x6's. The total will be "x". But then they go back and change the number of 4x6's to 3. The only way I can think to address this is to each time assign the value of the sum values for each form element for that image. In other words, every time an onChange activates the func, cycle through each of the other 5 elements pertinent to that image, resulting in a new total... Am I warm?