![Antiguo](http://static.forosdelweb.com/fdwtheme/images/statusicon/post_old.gif)
20/12/2007, 14:02
|
![Avatar de agressor](http://static.forosdelweb.com/customavatars/avatar203215_1.gif) | | | Fecha de Ingreso: noviembre-2007 Ubicación: Knocking the Death Door..
Mensajes: 368
Antigüedad: 17 años, 2 meses Puntos: 3 | |
Re: Veis algun fallo en este codigo: Intenta con esto no lo he probado pero quiza te funcione...
function loadRandomPage()
{superior=18;
inferior=0;
numPosibilidades = superior - inferior
aleat = Math.random() * numPosibilidades
aleat = Math.round(aleat)
random_number= parseInt(inferior) + aleat ;
if (window.parent)
window.parent.location=link[random_number-1];
else
window.location=link[random_number-1];
}
function viewSource()
{
var current_url="";
current_url=document.location;
window.location="view-source:"+current_url;
}
function WinOpen()
{
alert('\nLa pagina se cargará en ventana completa.\n\n');
window.open("tu_pagina.htm","DisplayWindow","menub ar=yes,scrollbars=yes");
window.open("tu_pagina.htm","DisplayWindow","menub ar=yes,scrollbars=yes");
}
</SCRIPT><body background="imagenes/fondos/back08.jpg">
<div align="center">
<center>
<INPUT TYPE="button" VALUE="Pulsa para otra pregunta al azar" onClick="loadRandomPage()">
</div>
</body></html>
Espero te sirva..
Prueba y me cuentas..!
Salu2..! |