Forum Moderators: coopster
I have this form which has got all these drop down boxes which has values built in the html form, once selected they are all sent to the database table to be stored only when the authentication is done and for that record only.
I am also using the same form to retrieve information from the database and display back to the form. The problem is i am not able to display data retrieved from the database into the drop down boxes. Can someone please help me the code please.
Thanks much for the help.
<removed code dump, please see Charter [webmasterworld.com] in regards to posting guidelines>
[edited by: coopster at 6:23 pm (utc) on May 3, 2008]
[edit reason] Use example.com, thanks. [/edit]
// YOUR DB QUERY HERE
<select name="whatever">
<? while($yourqueryresults = mysql_fetch_assoc($resultsvalue)
{ ?>
<option value="<? echo $yourdbvalue; ?>" <? if($resultsoption == $pulledoption) { ?> selected <? } ?>><? echo $youroption; ?></option>
<? } ?></option>
</select>
Just a thought...may be a bit much...but it works in a pinch.