success! (learning about foreach())
Joshua S. Freeman
jfreeman at amnh.org
Wed May 21 16:14:27 EDT 2003
well.. I didn't do it using 'foreach'.. but I did do it using some code from
chapter 17 of the wrox book that was recommended by louie...
here's the working code:
$query= mysql_query("select * FROM taxa_order");
print ("<select name=\\"order\\">");
while ($row = mysql_fetch_row($query)) {
print "<option value=\\"$row[0]\\">$row[1]</option>";
and the result:
<select name="order"><option value="1">Hymenoptera</option>
which is exactly what I was trying to do...
now.. if only i could figure out how to get the same result using
'foreach'...
J.
More information about the talk
mailing list