primero script:
Código PHP:
<?php
$link = mysql_connect("host", "*****", "*****");
mysql_select_db("dbequipelsol", $link);
$conn = mysql_query("SELECT * FROM fotos");
$picrow=mysql_fetch_array($conn);
$mime = $picrow['mime'];
header("Content-type: $mime" );
echo "$picrow[foto]";
?>
Segundo script:
Código PHP:
<?php
$link = mysql_connect("host", "*****", "*****");
mysql_select_db("dbequipelsol", $link);
$conn = mysql_query("SELECT * FROM fotos");
while ($picrow=mysql_fetch_array($conn))
{
echo "<tr>
<td><img src='muestra_imagen.php?idfoto=".$picrow['idfoto']."' /></td>
</tr>";
} ?>