 var lastNav = -1; // Store the last menu shown
 function showSubMenu(pageId) {
   theTable = document.getElementById("sub" + pageId);
   theTable.style.display = "";
   theMain = document.getElementById("main" + pageId);
   theMain.style.background='url(./images/mainnavgrbg.gif)';
   if (lastNav != -1 && lastNav != pageId) {
     hideSubMenu(lastNav);
   }
   lastNav = pageId;
 }

 function hideSubMenu(pageId) {
   theTable = document.getElementById("sub" + pageId);
   theTable.style.display = "none";
   theMain = document.getElementById("main" + pageId);
   theMain.style.background='url(/images/navblbar.gif)';
 }

