var inmenu=false;
var lastmenu=0;
function Menu(current) {
   if (!document.getElementById) return;
   inmenu=true;
   oldmenu=lastmenu;
   lastmenu=current;
   if (oldmenu) Erase(oldmenu);
   m=document.getElementById("menu-" + current);
   box=document.getElementById(current);
//Next line controls horizonal placement on page
   box.style.left= m.offsetLeft;
//Adding value in next line is offset from top of screen
   box.style.top= m.offsetTop + m.offsetHeight + 310;
   box.style.visibility="visible";
   m.style.backgroundColor="yellow";
   box.style.backgroundColor="#cc9900";
//Next instruction controls initial width of drop drown box
   box.style.width="150px";
}
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="#cc9900";
}
function Timeout(current) {
   inmenu=false;
   window.setTimeout("Erase('" + current + "');",300);
}
function Highlight(menu,item) {
   if (!document.getElementById) return;
   inmenu=true;
   lastmenu=menu;
   obj=document.getElementById(item);
   obj.style.backgroundColor="yellow";
}
function UnHighlight(menu,item) {
   if (!document.getElementById) return;
   Timeout(menu);
   obj=document.getElementById(item);
   obj.style.backgroundColor="#cc9900";
}
var tableColor = "#cc9900"; // light brown

function shighlight(item) {
if (!document.getElementById) return;
obj=document.getElementById(item);
obj.style.backgroundColor="yellow";
}
function sunhighlight(item) {
if (!document.getElementById) return;
obj=document.getElementById(item);
obj.style.backgroundColor= tableColor;
}


