Good morning, I am working with variables within option value, but I can not avoid repeated options, in the database the box field the information it contains is repeated but I do not know how to show it only once the information within the select and that the others are omitted, thank you very much.
<form role="form" name="caja" enctype="multipart/form-data" action="muestra_archivo.php" method="POST">
<TR ALIGN=CENTER>
<th><label for="caja">Seleccionar caja: </label></th>
<?php
$res1 = $mysqli->query($query);
?>
<td><select name="caja">
<?php
while ( $rw = $res1->fetch_array() )
{
?>
<option value="<?php echo $rw['caja']; ?>" >
<?php echo $rw['caja']; ?>
</option>
<?php
}
?>
</select>
</td>
<TD><input type="submit" value="Aceptar"></TD>
</form>
</TR>
</table>