<INPUT TYPE="file" NAME="html_file" ACCEPT="text/html">
Como hago para detectar si alguien puso la imagen en el formulario o no? Es decir:
Código PHP:
<?
$texto1=$_POST[texto1];
$texto2=$_POST[texto2];
$imagen=$_POST[html_file];
if($_POST[html_file] == NULL){ echo "No hay imagen";}
else{ echo "Hay imagen" }
?>
Código HTML:
<form enctype="multipart/form-data" method="post" action=""> <input name="texto1" maxLength="150" type="text" size=35> <input name="texto2" maxLength="150" type="text" size=35> <input name="html_file" type="file" accept="text/html"> <input type="submit" name="Submit" value="Submit">
Gracias!