initMenu = function() 
{ 
 	// loop through menu
	navRoot = document.getElementById("menu").firstChild;
	for ( i=0; i < navRoot.childNodes.length; i++ ) 
	{
		var node = navRoot.childNodes[i]; 
		if ( node.nodeName == "LI" ) 
		{
			// show
			node.onmouseover = function() 
			{
				for ( i=0; i<this.childNodes.length; i++ ) 
					{
						if( this.childNodes[i].nodeName == 'UL' ) 
						{
							var popup_list = this.childNodes[i]; // reference for later
							popup_list.style.display = 'block';
							break;
						}
					}
				// fix for IE - selects appear over popup unless an iframe is positioned under the DIV
				if( ( document.all && document.getElementById ) && document.getElementsByName( 'select_concealer' ) )
				{
					// reference iframe
					for ( i=0; i<this.childNodes.length; i++ ) 
					{
						if( this.childNodes[i].nodeName == 'IFRAME' && this.childNodes[i].getAttribute('name') == 'select_concealer' )  
						{
							iframe = this.childNodes[i];
							break;
						}
					}
					// apply settings
					popup_list.style.zIndex = 100;
					iframe.style.width = popup_list.offsetWidth;
					iframe.style.height = popup_list.offsetHeight + 3;
					iframe.style.top = popup_list.style.top;
					iframe.style.left = popup_list.style.left - 1;
					iframe.style.zIndex = popup_list.style.zIndex - 1;
					iframe.style.filter = 'progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=0)';
					iframe.style.display = "block";
				}
			}
			// hide
			node.onmouseout=function() 
			{
				for ( i=0; i<this.childNodes.length; i++ ) 
				{
					if( this.childNodes[i].nodeName == 'UL' ) 
					{
						this.childNodes[i].style.display = 'none';
						break;
					}
				}
				// fix for IE again
				if( ( document.all && document.getElementById ) && document.getElementsByName( 'select_concealer' ) )
				{
					for ( i=0; i<this.childNodes.length; i++ ) 
					{
						if( this.childNodes[i].nodeName == 'IFRAME' && this.childNodes[i].getAttribute('name') == 'select_concealer' )  
						{
							this.childNodes[i].style.display = "none";
							break;
						}
					}
				}
			}
		}
	}
}
addLoadEvent( initMenu );