function startList() {
//private
/* builds the top navigation lists 
	buildList()*/
/* calls setEvent for the topNav eleement */
	if (document.all&&document.getElementById) {
		navRoot = document.getElementById("topNav");
		
		setEvent(navRoot);	
		
	}
}

function setEvent(rootNode){
//private
/* sets the events for LI items that are children of rootNode */
/* [in]	rootNode	 the node object to be crawled */
	
	var i
	for (i=0; i<rootNode.childNodes.length; i++) {
		var node = rootNode.childNodes[i];
			/*alert(node.nodeName + ':' + node.id + ':' + node.className); test code */
		
		if (node.nodeName=="li" ||node.nodeName=="LI") 
		{
			
			node.onmouseover=function() {
				this.className+=" over";
			}
			node.onmouseout=function() {
				this.className=this.className.replace(" over", "");
				
			}
			setEvent(node);
		} else {
			setEvent(node);
		}
	}
}

function setCurrent(currentID){
//sets the class of current 
//[in] id of the element to have its class set to current
    
    //check that browser can handle this script -- add this later if needed
    if(!document.getElementById){ return false;}
    //check that id exists
    if(document.getElementById(currentID)){
        var obj = document.getElementById(currentID)
        if (obj.className != null) {
            obj.className = obj.className + ' current';
        }else {
            obj.className = 'current';
        }
    }else {
        //alert("cannot find element" + currentID);
    }
    //append the style class current to its style attribute
    
    
}

