Hi, I'm populating an html combobox from a mysql data table, the weird thing is that the first record is not displayed, here it is the php code:
$sql1="SELECT * from $tabla8";
$rs1=mysqli_query($conn, $sql1) or die(mysqli_error($conn));
$filas1=mysqli_num_rows($rs1);
$rsdeptos = mysqli_fetch_assoc($rs1);
and here it is the html code:
Depto Levantamiento <SELECT name="txtdeplev" id="txtdeplev">
<OPTION selected value="0">(Escoga un valor:)</OPTION>
<?php
while($row=mysqli_fetch_assoc($rs1)){
echo "<option value='" . $row['coddep'] . "'>" . $row[ 'nomdep' ] . "</option>";
}
?>
</SELECT></TD>
</TR>
for example If I have 4 records in $table1:
data1, data2, data3, data4
the html combobox display only three, like this:
data2
data3
data4
so, my question is: how can I populated and display in my combo all the records from the table?
regards