﻿// $Id: subnavjavascript.js,v 1.2 2008/05/30 18:06:46 jchung Exp $

var isDom = (document.getElementById && document.getElementsByTagName);
var subNavBox;
var subNavArr;
var subNavGroups = new Array();
var group;

function getSubNavs() {
	subNavBox = document.getElementById('globalSubNavContainer');
	subNavArr = subNavBox.getElementsByTagName('ul');
	var j=0;
}

function ShowSubnav(navDepId){

  //decrement the id to match possition in the array.
  navDepId--;
  if(subNavArr){
    subNavArr[navDepId].style.display= "inline";
    
    for(var i =0; i < subNavArr.length; i++){
      if(i != navDepId){
        subNavArr[i].style.display = "none";
  
      }     
    } 
  }
}

function HideSubnav(navDepId){
  
  //decrecment the id to match the possition in the array.
  navDepId--;
  setTimeout("subNavArr["+navDepId+"].style.visibility = 'hidden'", 10*1000);

}


