var moz = (document.nodeName)? true:false;	// Check if browser is mozilla
var ie = (document.all)? true:false;		// Check if browser is ie

function next(i) {
	current = (ie)? document.all("paragraph"+i) : document.getElementById("paragraph"+i);
	current.style.visibility = 'hidden';
	i++;
	if (i > 3) i = 1;
	current = (ie)? document.all("paragraph"+i) : document.getElementById("paragraph"+i);
	current.style.visibility = 'visible';
}
	
function getFlashVersion() {
	var flashversion = 0;
	if (navigator.plugins && navigator.plugins.length) {
		x = navigator.plugins["Shockwave Flash"];
		if(x){
			if (x.description) {
				y = x.description;
				flashversion = y.charAt(y.indexOf('.')-1);
			}
		}
	} else {
		result = false;
		for(var i = 15; i >= 3 && result != true; i--){
			execScript('on error resume next: result = IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.'+i+'"))','VBScript');
			flashversion = i;
		}
	}
	return flashversion;
}


function detectFlash(ver) {      
	if (getFlashVersion() >= ver) return true;
	else return false;
}

function getBrowserVersion() {
	
	if (navigator.userAgent.indexOf('Safari')!=-1) return "safari";
	if (navigator.userAgent.indexOf('MSIE 6.')!=-1) return "ie6";
	if (navigator.userAgent.indexOf('Mozilla/5')!=-1) return "moz5";
	
}

function detectBrowser(ver) {
	if (getBrowserVersion() >= ver) return true;
	else return false;
}

if (detectFlash(6)) this.location = "fmx.html";
else if (! (detectBrowser('safari') || detectBrowser('ie6') || detectBrowser('moz5')) ) this.location = "upgrade.html";