function loadurl(url,containerid) {
	try {
		// Moz supports XMLHttpRequest. IE uses ActiveX. browser detction is bad.
		// object detection works for any browser
		xmlhttp = window.XMLHttpRequest?new XMLHttpRequest():
		new ActiveXObject("Microsoft.XMLHTTP");
	}
	
	catch (e) {
		// browser doesn't support ajax. handle however you want
	}
	
	// the xmlhttp object triggers an event everytime the status changes triggered() function handles the events
	xmlhttp.onreadystatechange = function(){triggered(containerid)};
	
	// open takes in the HTTP method, url, and asynchronous = true or false.
	xmlhttp.open("GET", url, true);
	
	// send the request. if this is a POST request we would have sent post variables: send("name=aleeme"nder=male).
	// Moz is fine with just send(); but IE expects a value here, hence we do send(null);
	xmlhttp.send(null);
}

function triggered(containerid) {
	// if the readyState code is 4 (Completed) and http status is 200 (OK) we go ahead and get the responseText
	// other readyState codes: 0=Uninitialised 1=Loading 2=Loaded 3=Interactive
	if ((xmlhttp.readyState == 4) && (xmlhttp.status == 200)) {
		// xmlhttp.responseText object contains the response.
		document.getElementById(containerid).innerHTML = xmlhttp.responseText;
	} else {
		document.getElementById(containerid).innerHTML = "<br><br><div align=\"center\"><img src=\"images/loading.gif\" width=\"16\" height=\"16\" border=\"0\"></div><br><br>";
	}
}
