/**************************************************
 * Teknivision copyrights
 * all rights reserved
 * 10/01/06
 * www.teknivision.com
 **************************************************/
 function detectAll(OS, Version, Name, Lang)
{
	/*alert (OS + " " + Version + " " + Name + " " + Lang);*/
	if (OS == "Macintosh" && Name == "Internet Explorer" && Version <= 4) {
		if (Lang == "fr") {
			alert("Attention\r\nLe Site 25++ respecte la Norme W3C et est optimisé pour les navigateurs récents.\r\nVotre navigateur est trop ancien veuillez le mettre à jour.");
			this.location = "http://www.mozilla-europe.org/fr/products/firefox/";
		}
		if (Lang == "en") {
			alert("Warning\r\nthe 25++ WebSite respects the W3C Standard and is optimized for the most recent navigators.\r\nYour navigator is too old you, need to update it.");
			this.location = "http://www.mozilla-europe.org/en/products/firefox/";
		}
	}
	else if (OS == "Macintosh" && Name == "Netscape" && Version < 5) {
			if (Lang == "fr") {
				alert("Attention\r\nLe Site 25++ respecte la Norme W3C et est optimisé pour les navigateurs récents.\r\nVotre navigateur est trop ancien veuillez le mettre à jour.");
				this.location = "http://www.mozilla-europe.org/fr/products/firefox/";
			}
			if (Lang == "en") {
				alert("Warning\r\nthe 25++ WebSite respects the W3C Standard and is optimized for the most recent navigators.\r\nYour navigator is too old you, need to update it.");
				this.location = "http://www.mozilla-europe.org/en/products/firefox/";
			}
	}
	else if (OS == "Windows" && Name == "Internet Explorer" && Version < 4) {
		if (Lang == "fr") {
			alert("Attention\r\nLe Site 25++ respecte la Norme W3C et est optimisé pour les navigateurs récents.\r\nVotre navigateur est trop ancien veuillez le mettre à jour.");
			this.location = "http://www.microsoft.com/france/windows/ie/default.mspx";
		}
		if (Lang == "en") {
			alert("Warning\r\nthe 25++ WebSite respects the W3C Standard and is optimized for the most recent navigators.\r\nYour navigator is too old you, need to update it.");
			this.location = "http://www.microsoft.com/windows/ie/default.mspx";
		}
	}
	else if (OS == "Windows" && Name == "Netscape" && Version < 5) {
			if (Lang == "fr") {
				alert("Attention\r\nLe Site 25++ respecte la Norme W3C et est optimisé pour les navigateurs récents.\r\nVotre navigateur est trop ancien veuillez le mettre à jour.");
				this.location = "http://www.mozilla-europe.org/fr/products/firefox/";
			}
			if (Lang == "en") {
				alert("Warning\r\nthe 25++ WebSite respects the W3C Standard and is optimized for the most recent navigators.\r\nYour navigator is too old you, need to update it.");
				this.location = "http://www.mozilla-europe.org/en/products/firefox/";
			}
	}
}

function detectOS()
{	
	if (navigator.appVersion.indexOf("Win") > -1)
		return ("Windows");
	else if (navigator.appVersion.indexOf("Macintosh") > -1)
		return ("Macintosh");
	else if (navigator.appVersion.indexOf("X11") > -1)
		return ("Unix");
	else if (navigator.appVersion.indexOf("Unix") > -1)
		return ("Unix");
	else if (navigator.appVersion.indexOf("Linux") > -1)
		return ("Unix");
	else
		return ("Unknown");
}

function detectVersion()
{
	return parseFloat(navigator.appVersion);
}

function detectName()
{
	if (navigator.appName.indexOf("Netscape") > -1)
		return ("Netscape");
	if (navigator.appName.indexOf("Explorer") > -1)
		return ("Internet Explorer")
	else
		return ("Unknown");
}

function detectLang() 
{
	if (navigator.browserLanguage) {
		var language = navigator.browserLanguage;
		if (language.indexOf("fr") > -1)
			return ("fr");
		else
			return ("en");
	}
	else {
		var language = navigator.language;
		if (language.indexOf("fr") > -1)
			return ("fr");
		else
			return ("en");
	}
}

detectAll(detectOS(), detectVersion(), detectName(), detectLang());