ive got a little problem. i have select boxes that load database values like location, times, etc. the three i am using are rooms, and start and finish times. they look like so
<?php
mysql_connect('localhost','root');
mysql_select_db('Health');
$result = mysql_query("SELECT Time FROM times");
echo "<SELECT valign=\"middle\" name=\"Start_Time\">\n";
while($row = mysql_fetch_assoc($result)) {
echo "<OPTION value=\"{$row['Time']}\">{$row['Time']}</OPTION>\n";
}
echo "</SELECT>\n";
?>
when i click submit, it goes to another page with an insert statement.
$sql = "INSERT INTO roster (Location,Room_Name,Start_Time,Finish_Time,Date,Service_Providing,Practitioner_ID) VALUES ('$Location','$Rooms','$Start_Time','$Finish_Time','$Date','$service_p','$prac_id')";
all the other variables insert fine into the database. only the 3 select statements dont go in. am i referring to them incorrectly? can someone see what im doing wrong?