/************/
/*** VARS ***/
/************/
var MENU_IN = 0;


// Funzione per patch IE su EMBED
function doFlash(path,width,height) {
    var flash = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width="'+width+'" height="'+height+'">';
    flash += '<param name="movie" value="'+path+'">';
    flash += '<param name="quality" value="high">';
    flash += '<param name="allowScriptAccess" value="always">';
    flash += '<param name="wmode" value="opaque">';
    flash += '<embed src="'+path+'" quality="high" allowScriptAccess="always" wmode="opaque" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="'+width+'" height="'+height+'"></embed>';
    flash += '</object>';
    document.write(flash);
}

// Funzione per gestire il menu
function menu(val) {
    var aTop = document.getElementById('top').getElementsByTagName('a')[val];
    var aBottom = document.getElementById('top').getElementsByTagName('a')[MENU_IN];
	//var pNew = document.getElementById('bottom').getElementsByTagName('p')[val];
	//var pOld = document.getElementById('bottom').getElementsByTagName('p')[MENU_IN];
	
	aBottom.className = 'top';
	aBottom.style.left = (120*MENU_IN)-1+'px';
    eval("aBottom.onmouseover = function () {menu("+MENU_IN+");};");
	//pOld.style.display = 'none';
	
    aTop.className = 'bottom';
    aTop.style.left = (aTop.style.left.substring(0,aTop.style.left.indexOf('px'))*1)-2+'px';
    aTop.onmouseover = function () {};
    //pNew.style.display = 'block';

    MENU_IN = val;
}
