	/*
		This script (c) 2000 Ivanopulo / DAMN -- http://www.damn.to
		You're free to use it, but please leave this message intact if you do it.
		
		Thanks alot to Marek for making this script NN6 compatible
		
		NN6 notice: It's *very* slow when it comes to timers, and it's an understatement!)
		
		Opera notice: Opera can identify itself as any browser, depending on value chosen
		in Preferences / Connections / Browser identification. This script assumes that it
		identifies itself as Opera. I dare not say it's a bold assumption, but it's default
		is MSIE 5. Go figure.
		
		EAToscana Webmaster notice : deleted compatibility foward NN and Opera
	*/
	
	function OnLoad()
	{
		var st = document.body.scrollTop;
		if (st == 0)
			menu.style.top = 152;
		else if (st < 152)
			menu.style.top = 152 + st;
		else
			menu.style.top = st;
			
		setTimeout ("OnLoad()", 500);
		return true;
	}

	function showMap()
   	{
		   if (GBrowserIsCompatible())
		   {
       		 // Crea un nuovo marker nel punto specificato con una descrizione HTML associata
			 function createMarker(point, description)
			 {
             var marker = new GMarker(point);
             GEvent.addListener(marker, "mouseover", function() { marker.openInfoWindowHtml(description); });
             return marker;
       		 }
   		   }
		      
		   if (GBrowserIsCompatible())
		   {
            
            // Ottiene l'elemento della pagina chiamato "map" (il DIV) 
            //   e crea la mappa utilizzandolo come contenitore.
            var map = new GMap2(document.getElementById("map"));                
            
            // Aggiunge dei controlli per lo zoom e lo spostamento 
            map.addControl(new GSmallMapControl());	            
            map.addControl(new GMapTypeControl()); 
            // Centra la mappa su EA Toscana, con uno zoom di 16 (min=0; max=17) 
            map.setCenter(new GLatLng(43.802687,11.181786), 15);
			// Aggiungi il marker alla mappa
		    map.addOverlay(createMarker(new GLatLng(43.802687,11.181786), "EA Toscana s.r.l<br />Via B.Cavalieri, 73<br />50019 Sesto Fiorentino (FI)"));
           }
     }
		 
	function swap (id, img)
	{
		eval ("document.all." + id + ".src = 'images/" + img + "';");
	}
	
	function orologio ()
	{
		data = new Date ();
		
		giorno = data.getDay ();
		numgiorno = data.getDate ();
		if (numgiorno < 10) numgiorno = "0" + numgiorno;
		mese = data.getMonth () + 1;
		if (mese < 10) mese = "0" + mese;
		anno = data.getFullYear ();
		ore = data.getHours ();
		if (ore < 10) ore = "0" + ore;
		minuti = data.getMinutes ();
		if (minuti < 10) minuti = "0" + minuti;
		secondi = data.getSeconds ();
		if (secondi < 10) secondi = "0" + secondi;
		stringa = "";

		switch (giorno)
		{
			case 0:
			{
				stringa = "Domenica ";
				break;
			}
			case 1:
			{
				stringa = "Lunedì ";
				break;
			}
			case 2:
			{
				stringa = "Martedì ";
				break;
			}
			case 3:
			{
				stringa = "Mercoledì ";
				break;
			}
			case 4:
			{
				stringa = "Giovedì ";
				break;
			}
			case 5:
			{
				stringa = "Venerdì ";
				break;
			}
			case 6:
			{
				stringa = "Sabato ";
				break;
			}
		}

		stringa = stringa + " " + numgiorno + "/" + mese + "/" + anno + " - " + ore + ":" + minuti + ":" + secondi + "&nbsp;";
		document.all.orologio.innerHTML = stringa;
	}