jQuery(document).ready(function($){

	$("#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 () {}
	});
	
	var image1 = new Image();
	image1.src = DNN_skinPath + "images/home_hover.jpg";
	var image2 = new Image();
	image2.src = DNN_skinPath + "images/officeinfo_hover.jpg";
	var image3 = new Image();
	image3.src = DNN_skinPath + "images/patientinfo_hover.jpg";
	var image4 = new Image();
	image4.src = DNN_skinPath + "images/cosmetic-dentistry_hover.jpg";
	var image5 = new Image();
	image5.src = DNN_skinPath + "images/orthodontics_hover.jpg";
	var image6 = new Image();
	image6.src = DNN_skinPath + "images/general-treatment_hover.jpg";
	var image7 = new Image();
	image7.src = DNN_skinPath + "images/contactus_hover.jpg";

	$('.LinkIcon').rollover('_hover');

// flash features
	if ($("#featurebefore").length) {
		var so = new SWFObject("/features/loader.swf", "features", "500", "273", "9", "#FF6600");
		so.addVariable("config", "/features/config.xml");
		so.addVariable("xmlfile", "/features/beforeafter.xml");
		so.addParam("wmode", "transparent");
		so.addParam("quality", "high");
		so.write("featurebefore");
	}
	if ($("#featurebefore1").length) {
		var so = new SWFObject("/features/loader.swf", "features", "500", "273", "9", "#FF6600");
		so.addVariable("config", "/features/config.xml");
		so.addVariable("xmlfile", "/features/beforeafter1.xml");
		so.addParam("wmode", "transparent");
		so.addParam("quality", "high");
		so.write("featurebefore1");
	}

	if ($("#featurecrowns").length) {
		var so = new SWFObject("http://tools.televoxsites.com/features/crown.swf", "slideshow", "287", "300", "6", "#000000");
		so.addParam("wmode", "transparent");
		so.addParam("quality", "high");
		so.write("featurecrowns"); 
	}

	if ($("#featureimplants").length) {
		var so = new SWFObject("http://tools.televoxsites.com/features/implant.swf", "slideshow", "200", "195", "6", "#000000");
		so.addParam("wmode", "opaque");
		so.addParam("quality", "high");
		so.write("featureimplants"); 
	}
	
	if ($("#featureorthocommon").length) {
		var so = new SWFObject("/features/loader.swf", "features", "500", "273", "9", "#FF6600");
		so.addVariable("config", "/features/config.xml");
		so.addVariable("feature", "problems");
		so.addParam("wmode", "transparent");
		so.addParam("quality", "high");
		so.write("featureorthocommon"); 
	}

	if ($("#featureorthotypes").length) {
		var so = new SWFObject("/features/loader.swf", "features", "500", "273", "9", "#FF6600");
		so.addVariable("config", "/features/config.xml");
		so.addVariable("xmlfile", "/features/types.xml");
		so.addParam("wmode", "transparent");
		so.addParam("quality", "high");
		so.write("featureorthotypes");
	}

	if ($("#featureorthoemergency").length) {
		var so = new SWFObject("/features/loader.swf", "features", "500", "273", "9", "#FF6600");
		so.addVariable("config", "/features/config.xml");
		so.addVariable("feature", "emergencies");
		so.addParam("wmode", "transparent");
		so.addParam("quality", "high");
		so.write("featureorthoemergency");
	}

	if ($("#featureoral").length) {
		var so = new SWFObject("/features/loader.swf", "features", "500", "325", "9", "#FF6600");
		so.addVariable("config", "/features/config.xml"); so.addVariable("feature", "hygiene");
		so.addParam("wmode", "transparent");
		so.addParam("quality", "high"); so.write("featureoral");
	}

	if ($("#featuregum").length) {
		var sshow = new SWFObject("http://tools.televoxsites.com/features/gums.swf", "slideshow", "320", "200", "6", "#000000");
		sshow.addVariable("colorslocation", location.host+DNN_skinPath+"colors.txt");
		sshow.addParam("wmode", "transparent");
		sshow.write("featuregum");
	}

	if ($("#featuredev").length) {
		var sshow = new SWFObject("http://tools.televoxsites.com/features/dentaldevelopment.swf", "slideshow", "450", "400", "6", "#000000");
		sshow.addVariable("colorslocation", location.host+DNN_skinPath+"colors.txt");
		sshow.addParam("wmode", "transparent");
		sshow.write("featuredev");
	}

	if ($("#featuredoral").length) {
		var so = new SWFObject("/features/loader.swf", "features", "500", "325", "9", "#FF6600");
		so.addVariable("config", "/features/config.xml");
		so.addVariable("xmlfile", "/features/hygiene-dental.xml?v=1.01");
		so.addParam("wmode", "transparent");
		so.addParam("quality", "high"); so.write("featuredoral");
	}

	if ($("#featurerpe").length){
		var sshow = new SWFObject("http://tools.televoxsites.com/features/rpa2.swf", "slideshow", "270", "200", "6", "#000000");
    	sshow.addVariable("colorslocation", location.host+DNN_skinPath+"colors.txt");
   	 sshow.addParam("wmode", "transparent");
   	 sshow.write("featurerpe");
	}
	
	if ($("#featurewis").length){
		var sshow = new SWFObject("http://tools.televoxsites.com/features/wisdom.swf", "slideshow", "190", "205", "6", "#000000");
		sshow.addParam("wmode", "transparent");
		sshow.write("featurewis");
	}
	
	if ($("#featureroot").length){
		var sshow = new SWFObject("http://tools.televoxsites.com/features/rootcanal.swf", "slideshow", "350", "260", "6", "#000000");	
		sshow.addParam("wmode", "transparent");
		sshow.write("featureroot");
	}
	
});

//sIFR implementation
function pageScripts(){
	var perpetua = {  src: DNN_skinPath + 'flash/helvetica-neue.swf'};
	sIFR.activate(perpetua);
	sIFR.replace(perpetua, {
		selector: 'h1', 
		wmode: 'transparent', 
		src:  DNN_skinPath +  'flash/helvetica-neue.swf', 
		css: [ '.sIFR-root {color:#000000; font-size:24px; text-transform:capitalize; }']
	});
}
