php - dynamic html select boxes need to update mysql -


ok, 1 little confusing. have select dropdowns produced php. can 4 selects, or 30 select dropdowns. there's option values. here's have far

<?php while($row = mysql_fetch_assoc($notes)){ ?> <select name="milestone" id="milestone[<?php echo $row['id']; ?>]"> <option value="enrollment date">enrollment date</option> <option value="discharge date">discharge date</option> <option value="a/c start">a/c start</option> <option value="completion date">completion date</option> </select> <?php } ?> 

if have 4 select boxes, might have arrays follows: milestone[2134], milestone[2222], milestone[225], , milestone[1022]

the array number id of mysql table entry need update value of specific select dropdown. thinking maybe use milestone[][id] , loop through that?

any ideas since there might 20 select dropdowns?

thanks!

do want fetch values of options database id ? should mysql_fetch_array or mysql_fetch_object function instead of mysql_fetch_assoc. function returns number of results while 2 above returns number values.


Comments

Popular posts from this blog

django - How can I change user group without delete record -

java - EclipseLink JPA Object is not a known entity type -

java - Need to add SOAP security token -