Código PHP:
<select name="select" id="select" >
<option><? include("../conexion.php");
$sql="SELECT * FROM secciones ";
$resultado=mysql_query($sql,$conexion);
while($mostrar=mysql_fetch_assoc($resultado)){
echo"".$mostrar['fede']."";
}
?></option>
<option><? include("../conexion.php");
$sql="SELECT * FROM secciones ";
$resultado=mysql_query($sql,$conexion);
while($mostrar=mysql_fetch_assoc($resultado)){
echo"".$mostrar['elcritico']."";
}
?></option>
</select>
y despues le mando el form
Código HTML:
<form action="insert_critico.php" method="post" enctype="multipart/form-data" name="formulario"> <span class="Estilo5"></span> <table width="346" border="0"> <tr> <td width="59" class="Estilo9">Foto</td> <td width="277"><input name="fichero" type="file" /></td> </tr> <tr> <td width="59"><span class="Estilo9">Titulo <label></label> </span></td> <td width="277"><input name="titulo" type="text" size="40"/></td> </tr> <tr> <td><span class="Estilo9">Cuerpo</span></td> <td><label> <textarea name="cuerpo" id="textarea" cols="45" rows="5"></textarea> </label></td> </tr> <tr> <td><span class="Estilo9"> <label>Autor </label> </span></td> <td><input name="autor" type="text" size="40"/></td> </tr> <tr> <td><input name="submit" type="submit" value="Subir" /></td> <td> </td> </tr> </table> </form>