I have a table with 15 rows containing a number of textboxes. If I change a numerical value in the last box in a row then, from the next row down to the end, the values must start from one more than that value, and increment in each row. Thus, eg, I want this change to occur when I alter the 2 to 5 in the second row:
The cell code (generated with php) is:
echo "<input name='$name1' id='$name1' value='$i'
I suspect that your action in dismissing the alert() is causing the <form> to be "submitted" with no 'action' attribute set, so the page is reloading, which restores all of the default values. It's hard to say with just the code you posted. Try adding "return false;" after the alert() call in your 'onchange' setting.