var inmenu=false;
var lastmenu=0;
function Menu(current) {
if (navigator.userAgent.indexOf("MSIE") > 0)

        	{
        		C=(document.body.clientWidth-850)/2;
        		        	}
        else


            {
            		C=(window.outerWidth-850)/2;
            	}
   if (!document.getElementById) return;
   inmenu=true;
   oldmenu=lastmenu;
   lastmenu=current;
   if (oldmenu) Erase(oldmenu);
   m=document.getElementById("menu-" + current);
   box=document.getElementById(current);
   //box.style.left= m.offsetLeft + m.offsetWidth + C + 1;
   box.style.left= m.offsetLeft + + m.offsetWidth + C - 25;
   box.style.top= m.offsetTop + 140;
   box.style.visibility="visible";
   m.style.backgroundColor="#CCFFCC";
   //box.style.backgroundColor="#CCFFCC";
   box.style.width="150px";
   m.style.backgroundColor="#CCFFCC";
   m.style.fontWeight='bold';
   }
function Erase(current) {
   if (!document.getElementById) return;
   if (inmenu && lastmenu==current) return;
   m=document.getElementById("menu-" + current);
   box=document.getElementById(current);
   box.style.visibility="hidden";
   m.style.backgroundColor="#CC3333";
   m.style.fontWeight='normal';
}
function Timeout(current) {
   inmenu=false;
   window.setTimeout("Erase('" + current + "');",500);
}
function Highlight(menu,item) {
   if (!document.getElementById) return;
   inmenu=true;
   lastmenu=menu;
   obj=document.getElementById(item);
   obj.style.backgroundColor="#99CC99";
}
function UnHighlight(menu,item) {
   if (!document.getElementById) return;
   Timeout(menu);
   obj=document.getElementById(item);
   obj.style.backgroundColor="#CCFFCC";
}


