function ajaxpost(url,query) {
	//Clear our fetching variable
	var xmlhttp=false;
    var contentType = "application/x-www-form-urlencoded; charset=iso-8859-1";
	//Try to create active x object
	try {
	    xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
	}
	catch(e) {
	    try {
	         xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
	    }
	    catch(E) {
	         xmlhttp = false;
	    }
	}
	if(!xmlhttp && typeof XMLHttpRequest!="undefined") {
		xmlhttp = new XMLHttpRequest();
	}
	xmlhttp.open("POST",url,false);
	xmlhttp.setRequestHeader("Content-Type", contentType);
	if(typeof(xmlhttp.send)!="undefined") {
		xmlhttp.send(query);
	}
	else if(typeof(xmlhttp.load)!="undefined") {
		xmlhttp.async = false;
		xmlhttp.load(url);
    }
    if ( xmlhttp.parseError && xmlhttp.parseError.errorCode != 0 ) {
        return false;                       // failed
    }
    // HTTP response code
    if ( xmlhttp.status-0 > 0 &&
         xmlhttp.status != 200 &&          // OK
         xmlhttp.status != 206 &&          // Partial Content
         xmlhttp.status != 304 ) {         // Not Modified
        return false;                       // failed
    }
    return xmlhttp;
}
