// JavaScript Document
function $(str){
	return document.getElementById(str);
}

IEMenu = function() {
	if (document.all&&document.getElementById&&IE6){
		navRoot = document.getElementById("nav");
		lis = navRoot.getElementsByTagName('li');
		lisc = lis.length;
		for(i=0; i<lisc; i++) {
			lis[i].onmouseover=function(){ this.className+=" over"; }
			lis[i].onmouseout=function() { this.className=this.className.replace(" over", ""); }
		}
	}
}

/** onloadStack, allows for multiple events to happen onload **/
var __onloadStack = new Array();

window.onload = function() {
	for (i in __onloadStack) {
		__onloadStack[i]();
	}
}

function SetBar(){
	if ($("active")){
		left = $("active").parentNode.offsetLeft;
		$("orange").style.marginLeft= left + 'px';
	}
}

function white(strId){
	if (document.all){
		$(strId).filters[0].opacity=100;			
	}else{	
		$(strId).style.opacity=1;
	}
}


function fade(strId){
	var elem=$(strId);
	if (document.all){
		elem.filters[0].opacity=elem.filters[0].opacity -10;
		if(elem.filters[0].opacity>0){
			setTimeout("fade(\'"+strId+"\')",75);
		}else{
			elem.filters[0].opacity=0;
		}
	}else{
		elem.style.opacity=elem.style.opacity -0.1;
		if (elem.style.opacity>0){
			setTimeout("fade(\'"+strId+"\')",75);
		}else{
			elem.style.opacity=0;
		}
	}
}
