function overstate() 
{
	for(k=0;k<this.childNodes.length; k++) 
	{
		if(this.childNodes[k].nodeName == "UL")
		{
			//this.childNodes[k].style.left = (this.parentNode.parentNode.parentNode.parentNode.offsetLeft + 10) + "px";
		}
	}
	this.className += " over";
}

function outstate() 
{
	this.className = this.className.replace("over", "");
}

if (document.getElementById("mainmenu")) 
{
	var parentDiv = document.getElementById("mainmenu");
	for (j=0; j<parentDiv.childNodes.length; j++) 
	{
		if(parentDiv.childNodes[j].nodeName == "UL")
		{
			var navRoot = parentDiv.childNodes[j];
			for (i=0; i<navRoot.childNodes.length; i++) {
				node = navRoot.childNodes[i];
				if (node.nodeName == "LI") {
					node.onmouseover = overstate;
					node.onmouseout = outstate;
				}
			}
		}
	}
}