function initMenu() {
	
	id="navigation";
	var count = 0;	
	var a = document.getElementById(id).getElementsByTagName("A");
	
	while( count < a.length ) {
		if( a[count].parentNode.childNodes[2] ) {
			a[count].className += " parent";
		}
		a[count].parentNode.className+=" hide";
		a[count].parentNode.id=(id+"li"+count);
		
		a[count].parentNode.onmouseover=function(e){
			clearTimeout(window[id+this.id]);
			window[id+this.id]=setTimeout("document.getElementById('"+this.id+"').className='show'",100);
		};
		a[count].parentNode.onmouseout = function() {
			clearTimeout(window[id+this.id]);
			window[id+this.id]=setTimeout("document.getElementById('"+this.id+"').className='hide'",400);
		};
		a[count].onfocus = function() {
			var obj = this;
			while( obj.tagName != "DIV" ) {
				if( obj.tagName == "LI" ) {
					obj.className="show";
				}
				obj = obj.parentNode;
			}
		}
		a[count].onblur = function() {
			var obj = this;
			while( obj.tagName != "DIV" ) {
				if( obj.tagName == "LI" ) {
					obj.className="hide";
				}
				obj = obj.parentNode;
			}
		}
		count++;
	}	
}

if(typeof addEvent === "function") addEvent(window, "load", initMenu)
else window.onload = initMenu;
