Ver Mensaje Individual
  #5 (permalink)  
Antiguo 27/06/2004, 10:39
Colombo1
 
Fecha de Ingreso: junio-2004
Mensajes: 24
Antigüedad: 20 años, 7 meses
Puntos: 0
Claro, lo he sacado de la página de la página de Tunait, de donde tú me has dicho antes, como te he comentado, lo único que he hecho ha sido sustituir las imágenes de tunait por las mias.

<html>
<head>
<title>Pop up para fotos</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="javascript">
/************************************************** ***************************
Pop-up ajustada a foto. Script creado por Tunait!
Si quieres usar este script en tu sitio eres libre de hacerlo con la condición de que permanezcan intactas estas líneas, osea, los créditos.
No autorizo a publicar y ofrecer el código en sitios de script sin previa autorización
Si quieres publicarlo, por favor, contacta conmigo.
http://javascript.tunait.com/
[email protected]
************************************************** ****************************/

var titulopordefecto = "Perico de los palotes"; //Si no se especifica un título al llamar a la función colocará el que se especifique aquí
var ventana;
var cont=0;

function afoto(cual,titulo)
{
if(cont==1){ventana.close();ventana=null}
if(titulo==null){titulo=titulopordefecto}
ventana=window.open('','ventana','resizable=yes,sc rollbars=no')
ventana.document.write('<html><head><title>' + titulo + '</title></head><body style="overflow:hidden" marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" scroll="no" onUnload="opener.cont=0"><img src="' + cual + '" onLoad="opener.redimensionar(this.width, this.height)">');
ventana.document.close();
cont++;
}
function redimensionar(ancho, alto)
{
ventana.resizeTo(ancho+12,alto+28);
ventana.moveTo((screen.width-ancho)/2,(screen.height-alto)/2); //centra la ventana. Eliminar si no se quiere centrar el popup
}
</script>
</head>

<body bgcolor="#FFFFFF" text="#000000">
<table border="0" align="center" width="42%" bgcolor="#000000" height="106">
<tr>
<td width="30%">
<div align="center"><a href="#" onClick="afoto('fotos/tibidabo.jpg','Catedral del Tibidabo');return false"><img src="fotos/tibidabop.jpg" width="95" height="72" border="0"></a></div>
</td>
<td width="32%">
<div align="center"><a href="#" onClick="afoto('fotos/gato.jpg');return false"><img src="fotos/gatop.jpg" width="100" height="73" border="0"></a></div>
</td>
<td width="20%">
<div align="center"><a href="#" onClick="afoto('fotos/paloma.jpg');return false"><img src="fotos/palomap.jpg" width="62" height="72" border="0"></a></div>
</td>
<td width="18%">
<div align="center"><a href="#" onClick="afoto('fotos/alenanene.jpg');return false"><img src="fotos/alenanenep.jpg" width="54" height="84" border="0"></a></div>
</td>
</tr>
</table>
</body>
</html>