Lo script x totazione banner qui sotto funziona benissimo ma apre i links nella stessa pagina!!!
come faccio a far sì che cliccando sui banner, i links si aprano in una nuova finestra???
<html>
<head>
<script>
<!--
var ad=3;
var rnd;
var time=45000
url=new Array();
url[1]="url1.html";
url[2]="url2.html";
url[3]="url3.html";
img=new Array();
img[1]="img1.gif";
img[2]="img2.gif";
img[3]="img3.gif";
tool=new Array();
tool[1]="Tooltip 1";
tool[2]="Tooltip 2";
tool[3]="Tooltip 3";
stat=new Array();
stat[1]="Status Bar 1";
stat[2]="Status Bar 2";
stat[3]="Status Bar 3";
function rndm(){
rnd=Math.floor(Math.random()*ad)+1;
if(rnd==parent.form1.rnd.value)rndm();
else setad();
};
function setad(){
parent.form1.rnd.value=rnd;
document.ad.src=img[rnd];
document.ad.alt=tool[rnd];
timer=setTimeout("rndm()",time);
};
function adclick(){
top.location.href=url[rnd];
};
// -->
</script>
</head>
<body topmargin="0" leftmargin="0" marginheight="0" marginwidth="0" onload="rndm()" bgcolor="#ffffff">
<center>
[img]blank.gif[/img]
</center>
</body>
</html>

Rispondi quotando