<?php $link=mysql_query("SELECT * FROM imagenes WHERE=id_foto",$link); echo "<img src=$link[$ruta] >" ?>