// JavaScript Document


/***
 * Show tab
 * Hides all other tabs, sets buttons to inactive, then shows the specified tab and changes button class to active
 */
function showTab(tabName, objButton){;
	var arrTabIDs=new Array('requisiti', 'soluzioni', 'risultati');
	for (tabID in arrTabIDs){
		if (document.getElementById(arrTabIDs[tabID])) document.getElementById(arrTabIDs[tabID]).style.display="none";
		if (document.getElementById("btn" + arrTabIDs[tabID])) document.getElementById("btn" + arrTabIDs[tabID]).firstChild.className="";
	}
	if (document.getElementById(tabName)) document.getElementById(tabName).style.display="block";
	//alert(objButton);
	if (objButton) objButton.className="worktabactive";
}

function showMap(tabName, objButton){;
	var arrTabIDs=new Array('aeroporto', 'autostrada');
	for (tabID in arrTabIDs){
		if (document.getElementById(arrTabIDs[tabID])) document.getElementById(arrTabIDs[tabID]).style.display="none";
		if (document.getElementById("btn" + arrTabIDs[tabID])) document.getElementById("btn" + arrTabIDs[tabID]).firstChild.className="";
	}
	if (document.getElementById(tabName)) document.getElementById(tabName).style.display="block";
	//alert(objButton);
	if (objButton) objButton.className="worktabactive";
}