function startList() {
	if (document.all&&document.getElementById) {
		var navRoot = document.getElementById("nav");
		if( navRoot && navRoot != null ) {
			for (i=0; i<navRoot.childNodes.length; i++) {
				node = navRoot.childNodes[i];
				if (node.nodeName=="LI") {
					node.onmouseover=function() {
						this.className+=" over";
					}
					node.onmouseout=function() {
						this.className=this.className.replace(" over", "");
					}
				}
			}
		}
	}

}

function toggleDownloadBlock(e, show)
{
	if (e)
	{
		var parent = e.parentNode;		
		
		if (!isDiv(parent)) parent = parent.parentNode;
		
		var textNoneDiv = parent.parentNode.parentNode; //only toggle if child of div with class named "NoTextBlocks"
		
		if (textNoneDiv) 
		{
			if (textNoneDiv.className == "NoTextBlocks")
			{			
				if (isDiv(parent))
				{
					var pars = parent.getElementsByTagName("p");
					toggleDisplayElements(pars, show, "block");
					
					var imgs = parent.getElementsByTagName("img");
					toggleDisplayElements(imgs, show, "list-item");
				}
			}
		}				
	}
}

function toggleDisplayElements(elms, show, showType)
{
	if (elms)
	{
		if (show)
		{			
			for (var i =0; i < elms.length; i++)
			{					
				elms[i].style.display = showType;
			}		
		}
		else
		{
			for (var i =0; i < elms.length; i++)
			{					
				elms[i].style.display = "none";
			}
		}
	}	
}

function toggleBlocks(e, blocksID)
{
	if (e)
	{	
		var parent = e.parentNode;
		
		if (parent) 		
		{
			if (parent.className == "BlocksHidden")
				parent.className = "";
			else
				parent.className = "BlocksHidden";	
		}
	}
}					

function isDiv(element)
{	
	if (element.constructor)
		return element.constructor == HTMLDivElement;
	else
	{	
		return element.tagName == "DIV";
	}
}