﻿
// sfHover for CSS Rollover Dropdown Menus.

sfHover = function() {
//var sfEls = document.getElementById("TopNavi").getElementsByTagName("LI");
//	for (var i=0; i<sfEls.length; i++) {
//		sfEls[i].onmouseover=function() {
//			this.className+=" sfhover";
//		}
//		sfEls[i].onmouseout=function() {
//			this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
//		}
//	}
}
/*
sfHover2 = function() {
var sfEls = document.getElementById("NavMain").getElementsByTagName("LI");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className+=" sfhover2";
		}
		sfEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" sfhover2\\b"), "");
		}
	}
}
*/
if (window.attachEvent) window.attachEvent("onload", sfHover);
/*
if (window.attachEvent) window.attachEvent("onload", sfHover2);
*/

 function toggleDisplay(target,type) {
	// Checks to see if you're passing an ID or an object
	if (document.getElementById(target)) {
		target = document.getElementById(target);
	}
	// Checks if you specified a display type, or defaults to 'block'
	(type && type != '') ? (displayType = type) : (displayType = 'block');

	// Performs toggle
	if (target.style.display == 'none') {
		target.style.display = displayType;
	}
	else {
		target.style.display = 'none';
	}
}
//Function used by the Download_Center_New Asset

function ChangeVisibility(nID)
    {
        if(document.getElementById(nID).className == "DivVisible")
        {
            document.getElementById(nID).className = "DivInvisible";
        }
        else
        {
            document.getElementById(nID).className = "DivVisible";
        }
    }