over = function() { 

var sfEls = document.getElementById("nav").getElementsByTagName("LI"); 
for (var i=0; i<sfEls.length; i++) { 
	sfEls[i].onmouseover=function() { 
		this.className+=" over"; 
	} 
	sfEls[i].onmouseout=function() { 
		this.className=this.className.replace(new RegExp(" over\\b"), "");
		} 
	}




 sfEls = document.getElementById("localMenu").getElementsByTagName("LI"); 
 if (sfEls!=null) 
for (var i=0; i<sfEls.length; i++) { 
	sfEls[i].onmouseover=function() { 
		this.className+=" over"; 
	} 
	sfEls[i].onmouseout=function() { 
		this.className=this.className.replace(new RegExp(" over\\b"), "");
		} 
	}
	
} 



if (window.attachEvent) window.attachEvent("onload", over);



ns4 = (document.layers)? true:false
ie4 = (document.all)? true:false
if (navigator.appVersion.lastIndexOf('Win') != -1)
{
onwindows = true
} else {
onwindows = false
}

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function MM_findObj(n, d) { 
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}

function changeLang(lang){
	var indirizzo=window.document.location;
	var indirizzo= new String(indirizzo)
	if(lang == "E"){
		//alert(lang);
		var pos= indirizzo.lastIndexOf(".");
		var strfile=indirizzo.substring(pos);
		var path=indirizzo.substring(0,pos);
		//alert(path)
		window.document.location= path+"E"+strfile;
	}
	
	if(lang == "I"){
		//alert(lang);
		var pos= indirizzo.lastIndexOf(".");
		var strfile=indirizzo.substring(pos);
		var path=indirizzo.substring(0, pos-1);
		//alert(path)
		window.document.location= path+strfile;
	}
}

function toggleShowHide(evId){
    ele=document.getElementById("blocco"+evId);
    if(!(ele!=null && ele.style.display!=null)){
        alert('non trovo display di trEvento'+evId);
        return false;

    }
    if(ele.style.display!='none'){
        ele.style.display='none';
    }else{
        ele.style.display='block';
    }
   // saveShowStatus();
    //return true;
}


 function gotoAnchor(anch){
	document.location.href='#' + anch ;
}


function gioca() {
window.open("http://www.scintec.it/RetiNeurali/BeatFFnet/", "note","toolbar=no,border=0, directories=no,menubar=no,scrollbars=no,width=350,height=500,resizable=no");
}

function gioca2(strat) {
window.open("http://www.scintec.it/RetiNeurali/Fibnet/index.html", "note" ,"toolbar=yes,border=0, directories=no,menubar=yes,scrollbars=no,width=800,height=440,resizable=no");
}


function introdux() {
window.open("browniano.html", "note","toolbar=no,border=0, directories=no,menubar=no,scrollbars=no,width=600,height=500,resizable=yes");
}
function fig() {
window.open("Levy/brown1.jpg", "note","toolbar=no,border=0, directories=no,menubar=no,scrollbars=no,width=741,height=600,resizable=yes");
}
function fig3() {
window.open("Levy/levy1.jpg", "note","toolbar=no,border=0, directories=no,menubar=no,scrollbars=no,width=714,height=600,resizable=yes");
}
function fig4() {
window.open("Levy/levy2.jpg", "note","toolbar=no,border=0, directories=no,menubar=no,scrollbars=no,width=800,height=653,resizable=yes");
}

function openimage(url,w,h) {
  window.open(url, "fig","toolbar=no,directories=no,menubar=no,bordre=0,scrolbars=no,width="+ w +",height="+ h )
}
