<!--
var inmenu = false;
var lastmenu = 0;
function Menu(current, boxWidth, offset){
	if(!document.getElementById) return;
	inmenu = true;
	oldmenu = lastmenu;
	lastmenu = current;
	if(oldmenu) Erase(oldmenu);
	l = document.getElementById("link_" + current);
	m = document.getElementById("menu_" + current);
	l.style.textDecoration = "underline";
	box = document.getElementById(current);
	box.style.left = findPosX(m);
	box.style.top = findPosY(m) + m.offsetHeight - offset;
	box.style.width = boxWidth;
	box.style.visibility = "visible";	
	box.style.backgroundColor = "green";
}

function Erase(current){
	if(!document.getElementById) return;
	if(inmenu && lastmenu == current) return;
	m = document.getElementById("menu_" + current);
	l = document.getElementById("link_" + current);
	box = document.getElementById(current);
	box.style.visibility = "hidden";
	l.style.textDecoration = "none";
}

function Timeout(current){
	inmenu = false;
	window.setTimeout("Erase('" + current + "');", 400);
}

function Hightlight(menu, item){
	if(!document.getElementById) return;
	inmenu = true;
	lastmenu = menu;
	obj = document.getElementById(item);
	obj.style.backgroundColor = "#ffcc33";
}

function Unhightlight(menu, item){
	if(!document.getElementById) return;
	obj = document.getElementById(item);
	obj.style.backgroundColor = "green";
}

function findPosX(obj)
{
	var curleft = 0;
	if (obj.offsetParent)
	{
		while (obj.offsetParent)
		{
			curleft += obj.offsetLeft
			obj = obj.offsetParent;
		}
	}
	else if (obj.x)
		curleft += obj.x;
	return curleft;
}

function findPosY(obj)
{
	var curtop = 0;
	if (obj.offsetParent)
	{
		while (obj.offsetParent)
		{
			curtop += obj.offsetTop
			obj = obj.offsetParent;
		}
	}
	else if (obj.y)
		curtop += obj.y;
	return curtop;
}

//-->