I've got an option box with 2 options in it: Yes or No, with values of 1 or 0 respectively.
I am creating a page that selects variables from the datbase and displays them on a form that can be edited and re-submitted. This is just like any other content management system out there.
My question is, how would I code for these options boxes? How do you tell the broswer which option should be selected as default? Would an if elseif statement work for this? Thanks.
Here's the variable and the option box:
$myrow['Sold']
<select name="sold" size="1">
<option value="0">No</option>
<option value="1">Yes</option>
</select>