
	var status;
	var xmlhttp;
function loadChaseStatus() {
	if (window.XMLHttpRequest) { // code for Mozilla, Safari, ** And Now IE 7 **, etc 
        xmlhttp = new XMLHttpRequest();
        //xmlhttp = new ActiveXObject("MSXML2.XMLHTTP.4.0");
    } else if (window.ActiveXObject) { //IE 
        xmlhttp=new ActiveXObject('Microsoft.XMLHTTP');
    }
	if (typeof(xmlhttp)=='object') {
        xmlhttp.open('GET', 'http://texastailchaser.com/livechase/status.txt', false);
        xmlhttp.onreadystatechange=function(){};
        xmlhttp.send(null);
        status = xmlhttp.responseText;
        //alert(status);
        loadStatus();
  }
}

function loadStatus() {

  obj = document.getElementById("chaseStatus");

	if(status == "gray") {
		obj.innerHTML = "No chase planned for today.";
		obj.className = "csGray";
		tick_activeChase = false;
	}
	if(status == "green") {
		obj.innerHTML = "Chase Planned For Today. Stay Tuned!";
		obj.className = "csGreen";
		tick_activeChase = false;
	}
	if(status == "yellow") {
		obj.innerHTML = "Chase! On Road To Target Area! <br>(streaming video will commence soon)";
		obj.className = "csYellow";
		tick_activeChase = true;
	}
	if(status == "orange") {
		obj.innerHTML = "CHASE IN PROGRESS! <br>Approaching Storm With Live Video.";
		obj.className = "csOrange";
		tick_activeChase = true;
	}
	if(status == "red") {
		obj.innerHTML =  "STORM INTERCEPT IN PROGRESS!!! <br>LIVE Streaming Video!";
		obj.className = "csRed";
		tick_activeChase = true;
	}
	if(status == "white") {
		obj.innerHTML = "Chase ended for day.";
		obj.className = "csWhite";
		tick_activeChase = false;
	}		
}
