//sIFR implementation
function pageScripts(){
var ShelleyAllegroScript = {  src: DNN_skinPath + '/flash/amperzand.swf' };
sIFR.activate(ShelleyAllegroScript);
sIFR.replace(ShelleyAllegroScript, {
  selector: 'h1', 
  wmode: 'transparent', 
  src:  DNN_skinPath +  '/flash/amperzand.swf', 
  css: [ '.sIFR-root {color:#06213a; font-size:40px;}'  ]
});
}

//Menu implementation	   
jQuery(document).ready(function(){

	jQuery("#navigation > ul").superfish({
		hoverClass:"hover",
		pathClass:"overideThisToUse",
		delay:800,
		animation:{height:"show"},
		speed:"normal",
		oldJquery:false,
		disableHI:false,
		onInit:function () {},
		onBeforeShow:function () {},
		onShow:function () {},
		onHide:function () {}
	}).find(">li:has(ul)").mouseover(function () {
		jQuery("ul", this).bgIframe({opacity:true});
	}).find("a").focus(function () {
		jQuery("ul", jQuery("#navigation > ul >li:has(ul)")).bgIframe({opacity:true});
	});

	//jQuery(".LinkIcon").rollover();
	/*
	 menuImage2 = new Image(); 
	menuImage2.src = DNN_skinPath + "images/Home.jpg";
	menuImage1 = new Image(); 
	menuImage1.src = DNN_skinPath + "images/Home_hover.jpg";
		
	menuImage3 = new Image(); 
	menuImage3.src = DNN_skinPath + "images/officeInfo.jpg";
	menuImage4 = new Image(); 
	menuImage4.src = DNN_skinPath + "images/officeInfo_hover.jpg";

	menuImage5 = new Image(); 
	menuImage5.src = DNN_skinPath + "images/patientInfo.jpg";
	menuImage6 = new Image(); 
	menuImage6.src = DNN_skinPath + "images/patientInfo_hover.jpg";
	*/
//Home
	var PathHome = DNN_skinPath + "images/homeicon.jpg";
	jQuery("#navigation36").append("<a href='/LinkClick.aspx?link=36' title=''></a>");
	
	jQuery("#navigation36").find("img").mouseover(function () {
				var PathHomeON = DNN_skinPath + "images/home_hover.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});
	jQuery("#navigation36").find("img").mouseout(function () {
				var PathHomeON = DNN_skinPath + "images/homeicon.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});
	//End

	//Office Info
	var PathHome = DNN_skinPath + "images/officeinfo.jpg";
	jQuery("#navigation57").append("<a href='#' title=''></a>");

	jQuery("#navigation57").find("img").mouseover(function () {
				var PathHomeON = DNN_skinPath + "images/officeinfo_hover.jpg";
				jQuery(this).attr({ src:PathHomeON });

	});
	jQuery("#navigation57").find("img").mouseout(function () {
				var PathHomeON = DNN_skinPath + "images/officeinfo.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});
	//End
	//patientinfo Info
	var PathHome = DNN_skinPath + "images/forourpatients.jpg";
	jQuery("#navigation58").append("<a href='#' title=''></a>");

	jQuery("#navigation58").find("img").mouseover(function () {
				var PathHomeON = DNN_skinPath + "images/forourpatients_hover.jpg";
				jQuery(this).attr({ src:PathHomeON });

	});
	jQuery("#navigation58").find("img").mouseout(function () {
				var PathHomeON = DNN_skinPath + "images/forourpatients.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});
	//End
	//Treatment
	var PathHome = DNN_skinPath + "images/pediatrictreatment.jpg";
	jQuery("#navigation59").append("<a href='#' title=''></a>");

	jQuery("#navigation59").find("img").mouseover(function () {
				var PathHomeON = DNN_skinPath + "images/pediatrictreatment_hover.jpg";
				jQuery(this).attr({ src:PathHomeON });

	});
	jQuery("#navigation59").find("img").mouseout(function () {
				var PathHomeON = DNN_skinPath + "images/pediatrictreatment.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});
	
//Fun Stuff
	var PathHome = DNN_skinPath + "images/adulttreatment.jpg";
	jQuery("#navigation60").append("<a href='#' title=''></a>");

	jQuery("#navigation60").find("img").mouseover(function () {
				var PathHomeON = DNN_skinPath + "images/adulttreatment_hover.jpg";
				jQuery(this).attr({ src:PathHomeON });

	});
	jQuery("#navigation60").find("img").mouseout(function () {
				var PathHomeON = DNN_skinPath + "images/adulttreatment.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});

//Patient Login
	var PathHome = DNN_skinPath + "images/moreinfo.jpg";
	jQuery("#navigation90").append("<a href='#' title=''></a>");

	jQuery("#navigation90").find("img").mouseover(function () {
				var PathHomeON = DNN_skinPath + "images/moreinfo_hover.jpg";
				jQuery(this).attr({ src:PathHomeON });

	});
	jQuery("#navigation90").find("img").mouseout(function () {
				var PathHomeON = DNN_skinPath + "images/moreinfo.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});




//fun stuff
	var PathHome = DNN_skinPath + "images/funstuff.jpg";
	jQuery("#navigation91").append("<a href='#' title=''></a>");

	jQuery("#navigation91").find("img").mouseover(function () {
				var PathHomeON = DNN_skinPath + "images/funstuff_hover.jpg";
				jQuery(this).attr({ src:PathHomeON });

	});
	jQuery("#navigation91").find("img").mouseout(function () {
				var PathHomeON = DNN_skinPath + "images/funstuff.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});




//con
	var PathHome = DNN_skinPath + "images/contactus.jpg";
	jQuery("#navigation98").append("<a href='#' title=''></a>");

	jQuery("#navigation98").find("img").mouseover(function () {
				var PathHomeON = DNN_skinPath + "images/contactus_hover.jpg";
				jQuery(this).attr({ src:PathHomeON });

	});
	jQuery("#navigation98").find("img").mouseout(function () {
				var PathHomeON = DNN_skinPath + "images/contactus.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});



//pl
	var PathHome = DNN_skinPath + "images/patientlogin.jpg";
	jQuery("#navigation99").append("<a href='#' title=''></a>");

	jQuery("#navigation99").find("img").mouseover(function () {
				var PathHomeON = DNN_skinPath + "images/patientlogin_hover.jpg";
				jQuery(this).attr({ src:PathHomeON });

	});
	jQuery("#navigation99").find("img").mouseout(function () {
				var PathHomeON = DNN_skinPath + "images/patientlogin.jpg";
				jQuery(this).attr({ src:PathHomeON });
	});

	
});



jQuery(document).ready(function(){
	jQuery('.accordion h2').click(function() {
	jQuery(this).toggleClass('active').next().slideToggle('slow');
		return false;
	}).next().hide();
});


$(function() {
	if ($('#flash-video').position().top > $('body').height()) {
		flowplayer("flash-video", "flash/flowplayer-3.1.5.swf", {
			plugins: { controls: { url: 'flash/flowplayer.controls-tube-3.1.5.swf' } }
		});
	}
});
