SQL Dropdown Box

Soldato
Joined
30 Nov 2005
Posts
3,084
Location
London
Just wondered if its possible to have data from a database presented in a drop down box using SQL and PHP.

I'm sure it's a SELECT statement and Print but can't quiet work out how.

Thanks for any help.
 
Nearly there but they print as separate drop downs for each one.

I know its something to do with the Movenext but again my lack of knowledge fails me.

Code:
while (!$rs->EOF)
{
print "<select size='1' name='drop'>";
print "<option value = 'phonemodel'>$phones->value</option>";
print " </select>";
$rs->MoveNext();
}
 
Back
Top Bottom