n=8;
function Banner() {document.write ("<img src='images/banner/banner"+ Math.floor(Math.random()*n)+".jpg'></img>"); }

function Banner2() {document.write ("<img src='../../images/banner/banner"+ Math.floor(Math.random()*n)+".jpg'></img>"); }

function Banner3() {document.write ("<img src='../images/banner/banner"+ Math.floor(Math.random()*n)+".jpg'></img>"); }

function MM_openBrWindow(theURL,winName,features) {window.open(theURL,winName,features);}

function PrevFoto(img){
 
  foto1= new Image();
  foto1.src=(img);
  Controlla(img);
}
function Controlla(img){
  if((foto1.width!=0)&&(foto1.height!=0)){
    viewFoto(img);
  }
  else{
    funzione="Controlla('"+img+"')";
    intervallo=setTimeout(funzione,100);
  }
}

function viewFoto(img){
  largh=foto1.width+20;
  altez=foto1.height+25;
  stringa="width="+largh+",height="+altez;
  finestra=window.open(img,"",stringa);
}


