function fnSetFormTarget(strTarget)
{
	var myform;
	if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1)
	{
		myform = document.Form1;
	}
	else 
	{
		myform = document.forms["Form1"];
	}
	myform.action = strTarget
}
fnSetFormTarget(strFormTarget)

function CheckAjaxResponse(res) {
    if (res && res.error && res.error.Message) {
        alert(res.error.Message)
        return false
    }
    else {
        return true
    }

}

function querySt(ji) {
    hu = window.location.search.substring(1);
    gy = hu.split("&");
    for (i = 0; i < gy.length; i++) {
        ft = gy[i].split("=");
        if (ft[0] == ji) {
            return ft[1];
        }
    }
    return null
}
// Browser Window Size and Position
// copyright Stephen Chapman, 3rd Jan 2005, 8th Dec 2005
// you may copy these functions but please keep the copyright notice as well
function pageWidth() { return window.innerWidth != null ? window.innerWidth : document.documentElement && document.documentElement.clientWidth ? document.documentElement.clientWidth : document.body != null ? document.body.clientWidth : null; }

jQuery(document).ready(function() {
    
})
// IE6 PNG fix, menu fix
jQuery(document).ready(function() {
    jQuery('body').pngFix();
    jQuery('.mediaCluetip').cluetip({ splitTitle: '|', tracking: true, positionBy: 'mouse' });    
    if (pageWidth() < 1020) {
        jQuery('#nav li.Level1Item:gt(6) li ul.Level3').addClass('left');
    }
});

// IE drop down menu
sfHover = function() {
    if (document.getElementById("nav")) {
        var sfEls = document.getElementById("nav").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"), "");
            }
        }
    }
}
if (window.attachEvent) window.attachEvent("onload", sfHover);

