I could use some help with a problem I have encountered. I have a table that has multiple rows - the PHP adds the rows dynamically with no problems - however, I have a javascript - code below that allows the user the change the cell with an event handler and the PHP does not add the javascript when it add's the rows and new cells to the table. Any suggestions on how we can fix this problem. Thank you for your help..
<tr><form name="b1"><td id="mainCell" align="left">
<select name = "b2" size = "1">
<option selected value="white">R </option>
<option value="c67171"> C</option>
<option value="48d1cc"> A</option>
<option value="ffc125"> S </option>
</select>
<input type="button" value="S" onClick="changeObjectColor('maincell',document.b1.b2.options[document.b1.b2.selectedIndex].value);">
<input name="pt_name" type="text" size=30 ></td></form>
<td valign="bottom"align="center"><input name="sn_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="cna_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="pt_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="st_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="ot_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="msw_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="date_auth_req" type="text" size=7></td>
<td valign="bottom"align="center"><input name="ins_co_name" type="text" size=18></td>
<td valign="bottom"align="center"><input name="branch_num" type="text" size=2></td>
</tr>
<tr><td id="mainCell2" align="left"><form name="b2">
<select name = "b3" size = "1">
<option selected value="white">R </option>
<option value="c67171"> C</option>
<option value="48d1cc"> A</option>
<option value="ffc125"> S </option>
</select>
<input type="button" value="S" onClick="changeObjectColor('maincell2',document.b2.b3.options[document.b2.b3.selectedIndex].value);">
<input name="pt_name" type="text" size=30 ></td></form>
<td valign="bottom"align="center"><input name="sn_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="cna_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="pt_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="st_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="ot_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="msw_end_date" type="text" size=7></td>
<td valign="bottom"align="center"><input name="date_auth_req" type="text" size=7></td>
<td valign="bottom"align="center"><input name="ins_co_name" type="text" size=18></td>
<td valign="bottom"align="center"><input name="branch_num" type="text" size=2></td>
</tr>
PAW