Código PHP:
<html>
<head wight=345>
<script language='JavaScript'>
function ventanaSecundaria (URL)
{
window.open(URL,'ventana1','width=500, height=350, scrollbars=no, menubar=no, location=no, resizable=no,left=350,top=250')
}
</script>
</head>
<body >
<?php ver(); ?>
</body>
</html>
<?php
function ver()
{echo "<a href='javascript:ventanaSecundaria ('verFoto.php?ruta=$ruta')'> ABRIR POPUP</a>"; }
?>