Howdy-
I'm using the following code to create a select menu based on a mysql query.
function do_edit() {
$dbuser = ;
$dbpass = ;
$dbhost = ;
$db_link = mysql_connect($dbhost,$dbuser,$dbpass);
mysql_select_db(contentmanagement, $db_link) or die(mysql_error());
$query = mysql_query("select * from news");
echo "<select name=\"TargetField\">";
while ($dbrow = mysql_fetch_array($query) or die(mysql_error()))
{
echo "<OPTION>$dbrow[title]</OPTION>";
}
echo "</select>";
mysql_close($db_link);
}
And it works as expected until I get to the end of the while loop, anything beyond the end of the while doesn't get executed or printed I guess is more accurate. I've tried echo'ing and printing things to the screen after the end of the loop that don't have to do with query or script itself and they aren't being printed either. I had similar code working previously but lost it due to hardware failure and can't remember how I had it working. Any ideas appreciated.
Drew-