img.php Código PHP:
<?php
$imagen = $_GET['path'];
if (is_file($imagen))
{
$ext = substr($imagen, strrpos($imagen, '.') + 1); // extension
header('content-type: image/'.$ext);
readfile($imagen);
exit;
}
?>
me imagino que haciendo algo así, suerte!
Código HTML:
<img src="img.php?path=ruta/de/foo.jpg" alt="PHP"/>