I uploaded an image and clicked on "submit" I want you to show me the image in the page 'index.php'.Apresentando image in the browser
Code:
<html>
<body>
<form method="post" action="<?php echo $_SERVER['PHP_SELF'];?>">
Selecione : <input name="arquivo" type="file"/>
<input type="submit" value="Enviar"/>
</form>
<?php
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$aki = $_POST['arquivo'];
if (empty($aki)) {
echo "introduza de novo";
} else {
echo $aki;
}
}
?>
</body>
</html>
Result: Shows the file name and does not load the image as desired.