// JavaScript Document
// Browser Refs
ua=navigator.userAgent.toLowerCase();
docEl=document.getElementById?1:0;
IE=document.all&&!window.innerWidth&&ua.indexOf("msie")!=-1?1:0;
OPR=ua.indexOf("opera")!=-1&&document.clear?1:0;
OPR7=OPR&&document.appendChild?1:0;
NS=docEl&&!document.all&&ua.indexOf("opera")==-1?1:0;
NS4=document.layers?1:0;
vKON=ua.indexOf("konqueror")!=-1?parseFloat(ua.substring(ua.indexOf("konqueror/")+10)):0;
KON=vKON>=2.2?1:0;
KON3p=vKON>=3?1:0;
KON31p=vKON>=3.1?1:0;
MAC=ua.indexOf("mac")!=-1?1:0;
SAF=MAC&&ua.indexOf("safari")!=-1?1:0;
IE5M=MAC&&IE&&docEl?1:0;
IE4M=MAC&&IE&&!docEl?1:0;
IE4=!MAC&&IE&&!docEl?1:0;


// location linking
function go(url){
	document.location = url;
}

winIsLoaded = false;

function checkSize(){
	if (canResizeFlash) {
		if (getWindowHeight() < 804) {
			newH = 800;
		} else {
			newH = getWindowHeight();
		}
		setFlashHeight(obj, newH);

	}
}

function getWindowHeight() {
	if (NS) {
		winH = window.innerHeight;
	} else {
		winH = document.body.clientHeight;
	}
	return winH;
}

function setFlashHeight(obj, newH){
	document.getElementById(obj).style.height = newH + "px";
}

function setFlashSize(obj){
	if (canResizeFlash) {
		if (getWindowHeight() < 804) {
			newH = 800;
		} else {
			newH = getWindowHeight();
		}
		setFlashHeight(obj, newH);

	}
}

function canResizeFlash(){
	var ua = navigator.userAgent.toLowerCase();
	var opera = ua.indexOf("opera");
	if( document.getElementById){
		if(opera == -1) return true;
		else if(parseInt(ua.substr(opera+6, 1)) >= 7) return true;
	}
	return false;
}

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);
}

//-->

