Jump to content

Form With Js In For Loop


Muiter

Recommended Posts

The script below is working fin but I want to use the form in an for loop, how to change te form and JS te keep it working?<script> function bewerking_uren(form) { form.bewerking_tarief.value = form.bewerking.options[form.bewerking.selectedIndex].value } </script> <td><select name="bewerking" onChange="bewerking_uren(this.form)"> <option></option> <?php $sql_bewerking = "SELECT omschrijving, tarief from sp_calc_werkzaamheden ORDER BY omschrijving ASC"; $res_bewerking = mysql_query($sql_bewerking,$con); while ($row_bewerking = mysql_fetch_assoc($res_bewerking)){ ?> <option value=<?php echo $row_bewerking["tarief"] ?>><?php echo $row_bewerking["omschrijving"] ?></option> <?php } ?></select> </td> <td><input type="text" name="bewerking_tarief" size="5" value=" /></td>The original script can be found at http://mld.ursinus.edu/~jarana/Colby/template1.html

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...