
var passedVarsA = getUrlVars();
if(passedVarsA.id && passedVarsA.id != 1){
}else{
	var flashProxy = new FlashProxy('headerFlashId', 'resources/JavaScriptFlashGateway.swf');
}

function watchAgain(){
	if(readCookie('beenHere') && readCookie('beenHere')== "true"){
		eraseCookie('beenHere');
		window.location = 'default.aspx';
	}
	
}

function resizeFlash(){
	//alert('window has been resized');
	if(readCookie('beenHere') && readCookie('beenHere')== "true"){
		flashProxy.call('alignElements');
		//var theMovie = thisMovie("splash");
		//theMovie.goHome();
	}
}




function thisMovie(movieName) {
    if (navigator.appName.indexOf("Microsoft") != -1) {
        return window[movieName]
    }
    else {
        return document[movieName]
    }
}

function initIntro(){
	return;
	var passedVars = getUrlVars();
	//if(passedVars.id == 1){
		if(readCookie('beenHere') && readCookie('beenHere')== "true"){
			deleteIntro();
		}else{
			var swfDiv = getObject('headerFlash');
			swfDiv.style.visibility ='visible';
			createCookie("beenHere","true",1);

			var SO = new SWFObject("flash/splash2.swf", "headerFlashId", "100%", "100%", "8", "#FFFFFF");
			SO.addParam("wmode", "transparent");
			SO.addParam("scaleMode","noscale");
			SO.addParam("salign", "tl");
			SO.addParam("swLiveConnect", "true");
			SO.addVariable('lcId','headerFlashId');
			SO.write("headerFlash");
			
		}
	//}

}



function deleteIntro(){
	var obj = getObject('headerFlash');
	obj.style.zIndex = -1;
	obj.style.visibility = 'hidden';
	//window.document.body.style.overflow = 'scroll';
}//end function


function bodyNoScroll(){ 	window.document.body.style.overflow = 'hidden'; }

	
function getObject(id,silent){
	if (document.all) {	obj = document.all[id];	}
		else if (document.getElementById && !document.all) {	obj = document.getElementById(id);	} 
	if(silent != "silent"){
		if (!obj) {	alert(id+" is an unrecognized ID");
					return false;	}
	}//end silent if
	return obj;
}//end function

function getUrlVars()
{
    // Read a page's GET URL variables and return them as an associative array.
    //this function is from http://snipplr.com/view/799/get-url-variables/
    var vars = [], hash;
    var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');

    for(var i = 0; i < hashes.length; i++)
    {
        hash = hashes[i].split('=');
        vars.push(hash[0]);
        vars[hash[0]] = hash[1];
    }

    return vars;
}

//~~~~~~~~~~[ cookie functions ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//Cookie functions are from http://www.quirksmode.org/js/cookies.html
function createCookie(name,value,days) {
	if (days) {
		var date = new Date();
		date.setTime(date.getTime()+(days*24*60*60*1000));
		var expires = "; expires="+date.toGMTString();
	}
	else var expires = "";
	document.cookie = name+"="+value+expires+"; path=/";
}

function readCookie(name) {
	var nameEQ = name + "=";
	var ca = document.cookie.split(';');
	for(var i=0;i < ca.length;i++) {
		var c = ca[i];
		while (c.charAt(0)==' ') c = c.substring(1,c.length);
		if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
	}
	return null;
}

function eraseCookie(name) {
	createCookie(name,"",-1);
}