I'm trying to fill a selcet input field with data from a db table with 3 rows in it. Problem is, only 2 of the 3 are showing. Here my code.
<?php
$section_query = mysql_query("SELECT id,title FROM jos_sections") or die(mysql_error());
$sec_row = mysql_fetch_array($section_query);
while ($sec_row = mysql_fetch_array($section_query)) {
echo "<option value='".$sec_row[id]."'>".$sec_row['title']."</option>";
}
?>
</select>
could there be something preventing the query outputting the first row