This code creates one drop down menu for each item in the table. I’d like all the items in the table to be in one drop down menu. Seems like something simple in the html, but I can’t figure it out. Any help is appreciated. Thanks.
[php]<?php
$query = “SELECT typeid, foodtype from intlfoodtype”;
$result = mysql_query($query);
echo “<table class=“ex3” border=“0”>\n”;
while($row=mysql_fetch_array($result, MYSQL_ASSOC))
{
$typeid = $row[‘typeid’];
$foodtype = $row[‘foodtype’];
echo "<tr><td width=\"100\">\n";
echo "</td><td>\n";
echo "<select>";
echo '<option value="'.$typeid.'">'.$foodtype.'</option>';
echo "</td><td>\n";
echo "</td></tr>\n";
}
echo “”;
echo “\n”;
?>[/php]