﻿// Fonction d'affichage de menu

<!--


var timeOutGlobal;

//window.onload=initMenu;
document.getElementById('menustyle').href = "../css/menu_js.css";
window.onload=montre;

//alert(document.getElementById('smenu4').className.value);


function montre(id) {

	clearTimeout(timeOutGlobal);

	var d = document.getElementById(id);

	for (var i = 1; i<=300; i++) {

		if (document.getElementById('smenu'+i)) {document.getElementById('smenu'+i).className = "jsActive";}
		if (document.getElementById('smenu'+i)) {document.getElementById('smenu'+i).style.display='none';}

	}

	if (d) {d.style.display='block';}

}



function cache(id) {

	var d = document.getElementById(id);

	var command = "timeOutCache('"+id+"')";

	if (d) {

		timeOutGlobal = setTimeout(command,500);

	}

}



function timeOutCache(id) {

	var d = document.getElementById(id);

	if (d) {

		d.style.display='none';

	}

}

function initMenu() {
	
	for (var i = 1; i<=300; i++) {

		if (document.getElementById('smenu'+i)) {document.getElementById('smenu'+i).className = "jsActive";}

	}
	
	montre;
	
}

//window.onload=alert(document.getElementById('smenu4').className);
//window.onload=alert('tout');

//-->