/*/=====================================================================
	Start Javascript Functions
========================================================================/*/
/*/ Activate the sIFR3 /*/
var pageHeader = {src: DNN_skinPath+'harlow.swf'};
sIFR.activate(pageHeader);

sIFR.replace(pageHeader, {
  selector:'h1', 
  wmode:'transparent', 
  src: DNN_skinPath+'harlow.swf', 
  css:['.sIFR-root {color:#485D54; margin-left:7px;}' ]
});


/*/ Get the full path to the siteSkin folder /*/
var VirtualPath = location.href.substring(0,location.href.lastIndexOf('.com')+4 )
var DNN_skinPath = '/Portals/_default/Skins/siteSkin/'
var fullSkinPath = VirtualPath + DNN_skinPath
//alert(fullSkinPath)


/*/ Remove any elements by their id /*/
function removeElementById(idArray){
	var eraseList = idArray.split(",");
	for (i=0;i<eraseList.length;i++) {
		document.getElementById(eraseList[i]).style.display = 'none';
	}
//alert(eraseList.length);
}
/*Put this towards footer
and list items like an array*/
//removeElementById("homePhoto,pagePhoto");



/*/=====================================================================
	Start jQuery Functions
========================================================================/*/
jQuery(document).ready(function(){
									
	jQuery("#nav>ul")
	.superfish({
		hoverClass	: "sfHover",
		pathClass	: "overideThisToUse",
		delay		: 500,
		animation	: {opacity:"show",height:"show"},
		speed		: "normal",
		oldJquery	: false, // set to true if using jQuery version below 1.2
		disableHI	: false, // set to true to disable hoverIntent detection
		onInit		: function(){},
		onBeforeShow	: function(){},
		onShow		: function(){},
		onHide		: function(){}
	})
	
	.find("#nav>ul>li:has(ul)") //fixes ie6 bug
		.mouseover(function(){jQuery("ul", this).bgIframe({opacity:true});})
		.find("a").focus(function(){jQuery("ul", jQuery("#nav>ul>li:has(ul)")).bgIframe({opacity:true});});
	
	// remove last navDivider img
	jQuery("#nav>ul>li>a:last").css("border","none");

	/*/ Add Titles to All Links /*/
	jQuery('a').each(function() {
		var title = jQuery(this).text();
		jQuery(this).attr('title', title);
	});
	
	/*/ Remove Box from Links /*/
	jQuery('a').focus(function(){this.blur();});
	
	/*/ Remove those pesky non-breaking spaces /*/
	jQuery('.removeSpaces').each(function() {
		var content = jQuery(this).html();
		var newContent = content.replace(/&nbsp;/g, '');
		jQuery(this).html(newContent);
	});
	
	// remove last navDivider img
	jQuery("td[colspan=2]").css("text-align","center");
	//jQuery("td[colspan=2]>a.CommandButton").removeClass('CommandButton').addClass("submitButton");

});
