function createRequestObject() {
	// find the correct xmlHTTP, works with IE, FF and Opera
	var xmlhttp;
	try{xmlhttp=new ActiveXObject("Msxml2.XMLHTTP");}
  	catch(e){
    	try{xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");}
    	catch(e){xmlhttp=null;}
  	}
  	if(!xmlhttp&&typeof XMLHttpRequest!="undefined"){xmlhttp=new XMLHttpRequest();}
	return  xmlhttp;
}

var http = createRequestObject();

function sndReq(page,vars) {
    http.open('get', page+'?'+vars,true);
    http.onreadystatechange = handleResponse;
    http.send(null);
}

function handleResponse() {
	if(http.readyState == 4){
		var response = http.responseText;
        var update = new Array();

		if(response.indexOf('|' != -1)) {
			update = response.split('|');
			document.getElementById(update[0]).innerHTML = update[1];
		}
    }
}