function browser(){
	this.dom = (document.getElementById) ? true : false;
	this.ns4 = (document.layers) ? true : false;
	this.ie = (document.all && !window.opera) ? true : false;
	this.ns6 = this.dom && !this.ie
	this.ie4 = this.ie && !this.dom;
	this.opera = (navigator.userAgent.indexOf("Opera") != -1);
	this.mac = (navigator.appVersion.indexOf("Mac") != -1);
	this.macie4 = this.ie4 || this.mac;
	this.dhtml = (this.dom || this.ns4 || this.ie || this.ie4 || this.opera || !this.mac) ? true : false;
	this.dhtml = (this.mac)?false:true;
	this.ie7 = (document.all && !window.opera && window.XMLHttpRequest) ? true : false;
	return this;
}

var bw = new browser();

over = function() {
	var sfEls = document.getElementById("nav").getElementsByTagName("li");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			if(bw.ie && !bw.ie7){
				sel = document.getElementsByTagName("select");
				for (var i=0; i<sel.length; i++) {
					sel[i].style.visibility = 'hidden';
				}
			}
			this.className+=" over";
		}
	
		sfEls[i].onmouseout=function() {
			if(bw.ie && !bw.ie7){
				sel = document.getElementsByTagName("select");
				for (var i=0; i<sel.length; i++) {
					sel[i].style.visibility = 'visible';
				}
			}
			this.className=this.className.replace(new RegExp(" over\\b"), "");
		}
	}
}

if (window.attachEvent){ window.attachEvent("onload", over);}


function roll_over(current_name,new_state) {
	if (document.images) {
    	document[current_name].src = new_state;
    };
};

function toggleTable(el,st) {
	var myelement = document.getElementById(el);
	
	if(st == 1){
		if(bw.ie){
			myelement.style.display = "inline"
		}else{
			myelement.style.display = "table-cell"
		}
	}else{
		myelement.style.display = "none"	
	}	
}