
var ns = (document.layers);
var ie = (document.all);
var w3 = (document.getElementById && !ie);
function getXCrd() {
	var node = eval("indexImg");
	x = node.offsetLeft;
	while (node.parentNode) {
		node = node.parentNode
		if (node.offsetLeft) {
					x = x + node.offsetLeft
		}
	}
	return(x);           
}
function getYCrd() {
	var node = eval("indexImg");
	y = node.offsetTop;
	while (node.parentNode) {
		node = node.parentNode
		if (node.offsetLeft) {
					y = y + node.offsetTop
		}
	}
	return(y);           
}

function getXCoordinate(){
	xPos = eval("indexImg").offsetLeft;
	tempEl = eval("indexImg").offsetParent;
	while (tempEl != null) {
		xPos += tempEl.offsetLeft;
		tempEl = tempEl.offsetParent;
	}
	return xPos;
}
function getYCoordinate(){
	yPos = eval("indexImg").offsetTop;
	tempEl = eval("indexImg").offsetParent;
	while (tempEl != null) {
		yPos += tempEl.offsetTop;
		tempEl = tempEl.offsetParent;
	}
	return yPos;
}           

function mOver_Menu(menuId, add_x, add_y){
	if (ie){
		x = getXCrd();
		y = getYCrd();
		y = parseInt(y) + 92;
		if (navigator.platform != "Win32"){
			
		}
				
	}else if (w3){
		x = getXCoordinate();
		y = getYCoordinate()
	}else if (ns){
		x = getXCoordinate();
		y = getYCoordinate()
	}
	y = parseInt(y) + parseInt(add_y);
	x = parseInt(x) + parseInt(add_x);
	
	eval(menuId).style.top = y;
	eval(menuId).style.left = x;
	eval(menuId).style.visibility = "visible";
}
function mOut_Menu(menuId){
   //setTimeout(function (){closeMenu(menuId)}, 300) 
   eval(menuId).style.visibility = "hidden"; 
} 
function closeMenu(menuId){
	eval(menuId).style.visibility = "hidden";
}

