var callbackFunction

function createRequest(){
if(window.ActiveXObject){
xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
}
else if(window.XMLHttpRequest){
xmlHttp = new XMLHttpRequest();
		}
}



function ajax(url, func){

callbackFunction = func
	
createRequest();
xmlHttp.open("GET", url, true);
xmlHttp.onreadystatechange = StateChange;
xmlHttp.send(null);

return true;
}
	



function StateChange(){
if(xmlHttp.readyState == 4){

	callbackFunction(trim(xmlHttp.responseText))

}}