/************************************************/
/* Copyright 2010-2011 Lexigram, Andreas Tassos */
/************************************************/

function jsInitEnv() {

	var strver = navigator.appVersion + "\r\n";
	strver+= "Platform: " + navigator.platform + "\r\n";
	if ( strver.indexOf("MSIE 6.0") >= 0 ) {
		window.location = "updateie6.htm";
	}
	ajaxBringHTML("btnInitial");
	
}

function ajaxBringHTML(strID) {
	try {
		var xmlhttp;
		var strOut;
		var strFile;
		
		switch (strID) {
			case "btnProducts" :
				location.href="products/index.htm";
				return false;
			case "btnUpdates" :
				strFile = "updates.htm";
				break;			
			case "btnSeminars" :
				strFile = "seminars.htm";
				break;
			case "btnPatches" :
				strFile = "patches.htm";
				break;							
			case "btnInitial" :
				strFile = "initial.htm";
				break;
			case "btnInfo" :
				strFile = "info.htm";
				break;				
			case "btnMembers" :
				//window.open("http://91.205.174.143/ellinognosia/index.php", "_blank");
				//window.open("http://www.lexigram.gr/fix/live/index.php", "_blank");
				location.href="http://91.205.174.143/ellinognosia/choosesoft.htm";
				//location.href="http://www.lexigram.gr/fix/live/index.php";
				return false;
			case "btnGames" :
				location.href="http://91.205.174.143/ellinognosia/hangman.php";
				return false;
		}
		
		if (window.XMLHttpRequest) {
			xmlhttp = new XMLHttpRequest();
		} else {
			xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
		}					
		xmlhttp.onreadystatechange = function() {			
			if (xmlhttp.readyState == 4 && xmlhttp.status == 200) {				
				strOut = xmlhttp.responseText;
				document.getElementById("divDisplay").innerHTML = strOut;
			}
		}
		xmlhttp.open("GET", strFile, true);
		xmlhttp.send();
	}
	catch(err) {
		alert(err);
	}	
}

