//Create a boolean variable to check for a valid IE instance.
	var xmlhttp = false;
	
	//Check if we are using IE.
	try {
		//If the javascript version is greater than 5.
		xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
	} catch (e) {
		//If not, then use the older active x object.
		try {
			//If we are using IE.
			xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
		} catch (E) {
			//Else we must be using a non-IE browser.
			xmlhttp = false;
		}
	}
	
	//If we are using a non-IE browser, create a JavaScript instance of the object.
	if (!xmlhttp && typeof XMLHttpRequest != 'undefined') {
		xmlhttp = new XMLHttpRequest();
	}

// ON PAGE RUN CRUTIAL FUNCTIONS
//window.onload = function(){initialize();}

function initialize() {

	var message = document.getElementById('notice');
	
	if (message.firstChild){var query = 'id='+message.firstChild.id;}
	
	fx = new Animator({duration: 1000});
	fx.addSubject(new NumericalStyleSubject(message, 'opacity', 1, 0));
	fx.play();
	
	xmlhttp.open("GET", 'message.php?'+query);
		xmlhttp.onreadystatechange = function() {
			if (xmlhttp.readyState == 4 && xmlhttp.status == 200) {
				
				fadeIn(xmlhttp.responseText);
				
			}
		}
		xmlhttp.send(null);

}

function fadeIn(text){
	
	var message = document.getElementById('notice');
	
	fx = new Animator({duration: 1000});
	fx.addSubject(new NumericalStyleSubject(message, 'opacity', 0, 1));
	setTimeout(function(){message.innerHTML = text;fx.play();}, 1000);
	
	setTimeout(function(){initialize();}, 20000);
	

}
