Posted by peter on 06/11/07 21:35
> Try this:
>
> <SELECT NAME=\"country\">
> <OPTION SELECTED='selected'>$Row[country]</OPTION>
> <option>Afghanistan</option>
> <option>Aland Islands</option>
> <option>Albania</option>
> <option>etc etc </option>
> </select>
I think he actually means how does he populate the list of countries from a
list in the db.
To do this you need to loop through the results. Something like:-
echo "<SELECT NAME=\"country\">"
while ($row = mysql_fetch_array($db))
{
echo "<OPTION>$row[0]</OPTION>"
}
echo "</select>"
[Back to original message]
|