jarv
06-27-2008, 03:40 PM
At the moment my code outputs many select boxes with all dates, I want one select box with all the dates, how can i do this?
$result3 = mysql_query("SELECT HeaderDate FROM Headertbl");
while($row2 = mysql_fetch_array($result3))
{
$HeaderDate = $row2['HeaderDate'];
echo '<h2><select name="$HeaderDate"><option value="'.$HeaderDate.'">'.$HeaderDate.'</option></select></h2>';
}
$result3 = mysql_query("SELECT HeaderDate FROM Headertbl");
while($row2 = mysql_fetch_array($result3))
{
$HeaderDate = $row2['HeaderDate'];
echo '<h2><select name="$HeaderDate"><option value="'.$HeaderDate.'">'.$HeaderDate.'</option></select></h2>';
}