/*Menu implementation*/
jQuery(document).ready(function($){
	$("#navigation > ul").superfish({
		hoverClass:"hover",
		pathClass:"overideThisToUse",
		delay:300,
		animation:{height:"show"},
		speed:"fast",
		oldJquery:false,
		disableHI:false
	}).addClass('clearfix');
	
	$('#nav a[href="#"]').click(function() { return false });
	
	$("a").focus(function(){ this.blur(); });
	
	$('#navigation90 a').attr('target','_blank');
	
	// flash features
	if ($("#DentalDevelopement").length) {
		var so = new SWFObject("http://tools.televoxsites.com/features/dentaldevelopment.swf", "features", "450", "400", "9", "#FF6600");
		so.addParam("wmode", "transparent");
		so.addParam("quality", "high");
		so.write("DentalDevelopement"); 
	}
	
	//fix IE 7 of course
	zIndexWorkaround();
	
});

//sIFR implementation
function pageScripts(){
	var Futurabook = {  src: DNN_skinPath + 'Futurabook.swf' };
	sIFR.activate(Futurabook);
	sIFR.replace(Futurabook, {
	  selector: 'h1', 
	  wmode: 'transparent', 
	  src:  DNN_skinPath +  'Futurabook.swf', 
	  css: [ '.sIFR-root {color:#ffffff;font-size:27px;}'  ]
	});
}

function isIE()
{
    if(navigator.userAgent.match(/MSIE \d\.\d+/))
        return true;
    return false;
}

function zIndexWorkaround()
{
    if(isIE())
    {
        $("#navigation ul.Level1").parents().each(function() {
            var p = $(this);
            var pos = p.css("position");

            if(pos == "relative" ||
               pos == "absolute" ||
               pos == "fixed")
            {
                p.hover(function() {
                        $(this).addClass("on-top");
                    },
                    function() {
                        $(this).removeClass("on-top");
                    });
            }
        });
    }
}



