
	var key_tab = 9;
	var basic = true;

	function openWindow(theURL,winName,features) {
		if (winName.window) winName.focus;
		popupWin = window.open(theURL,winName,features)
		popupWin.focus;
	}
	function deleteConfirm(what,formName,theURL) {
		if (confirm("Are you sure you want to delete "+ what +"? ")) {
			if (formName != null) {
				formName.submit()
			} else {
				window.location.href = theURL
			}
		}
	}

	function processTab() {
		if (window.event.keyCode == key_tab) 
		{
		var s = document.selection;
		var tr = s.createRange();
		if ( tr != null ) 
			tr.text = "\t";
			window.event.returnValue=false;
		}
	}

/*************************************************************************
  This code is from Dynamic Web Coding at http://www.dyn-web.com/
  See Terms of Use at http://www.dyn-web.com/bus/terms.html
  regarding conditions under which you may use this code.
  This notice must be retained in the code as is!
*************************************************************************/

function getDocHeight(doc) {
  var docHt = 0, sh, oh;
  if (doc.height) docHt = doc.height;
  else if (doc.body) {
    if (doc.body.scrollHeight) docHt = sh = doc.body.scrollHeight;
    if (doc.body.offsetHeight) docHt = oh = doc.body.offsetHeight;
    if (sh && oh) docHt = Math.max(sh, oh);
  }
  return docHt;
}

function setIframeHeight(iframeName) {
  var iframeWin = window.frames[iframeName];
  var iframeEl = document.getElementById? document.getElementById(iframeName): document.all? document.all[iframeName]: null;
  if ( iframeEl && iframeWin ) {
    iframeEl.style.height = "auto"; // helps resize (for some) if new doc shorter than previous
    var docHt = getDocHeight(iframeWin.document);
    // need to add to height to be sure it will all show
    if (docHt) iframeEl.style.height = docHt + 30 + "px";
  }
}

function loadIframe(iframeName, url) {
  if ( window.frames[iframeName] ) {
    window.frames[iframeName].location = url;
    return false;
  }
  else return true;
}

////////////////////////// begin image preloading code -->

pic1 = new Image(182,24); 
pic1.src = "/styles/aaa/images/menu1_bkgnd_over.png";

pic2 = new Image(182,21); 
pic2.src = "/styles/aaa/images/menu2_bkgnd_over.png";

pic3 = new Image(1,25); 
pic3.src = "/styles/aaa/images/topmenu_bkgnd_over.png";

////////////////////////// <-- end image preloading code

////////////////////////// begin scrolling code -->

var heightarr = new Array();
var linka = new Array();

var nstazioni = datostazione.length;
var inoout=false;

var tmpv;
tmpv=400*parseInt(1);
var cvar=0,say=0,tpos=0,enson=0,hidsay=0,hidson=0;

var psy = new Array();
var uzunobj=null;
var uzuntop=0;
var toplay=0;

function mdivmo(gnum)
{
	/*
	inoout=true;

	if((linka[gnum].length)>2)
	{
		objd="d"+gnum;
		objd2="hgd"+gnum;
	
		document.getElementById(objd).style.color="#DBF7BF";
		document.getElementById(objd2).style.color="#F4ECAE";
	
		document.getElementById(objd).style.cursor='hand';
		document.getElementById(objd2).style.cursor='hand';
	
		document.getElementById(objd).style.textDecoration='none';
		bjd2.style.textDecoration='none';
	}
	window.status=""+linka[gnum];
	*/
}

function restime(gnum2)
{
	inoout=false;
	objd="d"+gnum2;
	objd2="hgd"+gnum2;

	//document.getElementById(objd).style.color="#DEE2ED";
	//document.getElementById(objd2).style.color="#FFFFFF";

	document.getElementById(objd).style.textDecoration='none';
	document.getElementById(objd2).style.textDecoration='none';

	window.status="";

}

function butclick(gnum3)
{
	/*
	if(linka[gnum3].substring(0,11)=="javascript:")
	{
		eval(""+linka[gnum3]);
	}
	else
	{
		if((linka[gnum3].length)>3)
		{
			if((trgfrma[gnum3].indexOf("_parent")>-1))
			{
				eval("parent.window.location='"+linka[gnum3]+"'");
			}
			else if((trgfrma[gnum3].indexOf("_top")>-1))
			{
				eval("top.window.location='"+linka[gnum3]+"'");
			}
			else
			{
				window.open(''+linka[gnum3],''+trgfrma[gnum3]);
			}
		}
	}
	*/
}

function dotrans()
{
	if(inoout==false){
	uzuntop--;
	if(uzuntop<(-1*toplay))
	{
		uzuntop=16;
	}

	document.getElementById('enuzun').style.pixelTop=uzuntop;
}
	if(psy[(uzuntop*(-1))+1]==3)
	{
setTimeout('dotrans()',3000+25);
}
else{setTimeout('dotrans()',25);}

}

function initte2()
{
	for(i=0;i<nstazioni;i++)
	 if((datostazione[i][7] != "n.p.") && (datostazione[i][7] != "---") )
	{
		objd="d"+i;
		if(parseInt(document.getElementById(objd).offsetHeight)<=0){setTimeout('initte2()',1000);return;}
	}
	i=0;
	for(i=0;i<nstazioni;i++)
	 if((datostazione[i][7] != "n.p.") && (datostazione[i][7] != "---") )
	{
		objd="d"+i;
		heightarr[i]=parseInt(document.getElementById(objd).offsetHeight);
	}

	toplay=1;
	for(i=0;i<nstazioni;i++)
	 if((datostazione[i][7] != "n.p.") && (datostazione[i][7] != "---") )
	{
		objd="d"+i;
		document.getElementById(objd).style.visibility="visible";
		document.getElementById(objd).style.pixelTop=toplay-3;
		psy[toplay]=3;
		toplay=toplay+heightarr[i]-1;
	}

	document.getElementById('enuzun').style.left=1+"px";
	document.getElementById('enuzun').style.height=toplay+"px";
	document.getElementById('enuzun').style.width=tmpv+"px";
	uzuntop=16;
	
	dotrans();
}

function initte()
{
	var pf_s = "<font style=\"font-size:9px;color:#AA2020;\">";
	
	i=0;
	divtexts = " style=\"position:absolute;visibility:hidden;width:"+tmpv+"; COLOR: #333333; left:0; top:0; FONT-FAMILY: MS Sans Serif,arial,helvetica; FONT-SIZE: 8pt; FONT-STYLE: normal; FONT-WEIGHT: normal; TEXT-DECORATION: none; margin:0px; overflow-x:hidden; LINE-HEIGHT: 12pt; text-align:left;padding:0px; cursor:default;\">";	
	innertxt = "<div id=\"enuzun\" style=\"position:absolute;left:0;top:0;\">";
	for(i=0;i<nstazioni;i++)
	 if((datostazione[i][7] != "n.p.") && (datostazione[i][7] != "---") )
	{
		innertxt = innertxt + "<div style=\"height:20px;\" id=d"+i+" onmouseover=\"mdivmo("+i+")\" onmouseout =\"restime("+i+")\" onclick=\"butclick("+i+")\""+divtexts+"<span id=\"hgd"+i+"\""+"><font style=\"font-size:12px;font-weight:bold;color:#3E4DB4;\">" + 
		datostazione[i][0] + " (" + datostazione[i][1] + ")</font>&nbsp;&nbsp;<font STYLE=\"font-family: Terminal; font-size:12px; color:#0000CC;\">&#016</font>&nbsp;"+pf_s+"Temp:</font> "+datostazione[i][7]+"°C"+"&nbsp;&nbsp;"+pf_s+"UR:</font> "+datostazione[i][8]+"%"+"&nbsp;&nbsp;"+pf_s+"Vento:</font> "+datostazione[i][11]+" Km/h "+datostazione[i][12]+"</span></div>";
	}
	innertxt = innertxt + "</div>";

	document.getElementById('spageie').innerHTML= "" + innertxt;
	setTimeout('initte2()',100);

}

//window.onload=initte;

////////////////////////// <-- end scrolling code