/*=================================================
Dependencies:
	none
*/

//=================================================
// Constant and variable declarations

// readyState status codes:
RS_UNINITIALIZED = '0';
RS_LOADING = '1';
RS_LOADED = '2';
RS_INTERACTIVE = '3';
RS_COMPLETE = '4';

// HTTP status codes:
HTTP_OK = '200';

//=================================================
// Detect browser and return an HTTP object for an Ajax call
// Based on code retrieved from: Dynamic Ajax Content - Dynamic Drive DHTML code library (www.dynamicdrive.com)
function getHTTPObject() {
	var httpObject = false;

	if (window.XMLHttpRequest)			// Mozilla et al
		httpObject = new XMLHttpRequest();
	else if (window.ActiveXObject) {	// IE
		try {
			httpObject = new ActiveXObject("Msxml2.XMLHTTP");
		} 
		catch (e) {
			try {
				httpObject = new ActiveXObject("Microsoft.XMLHTTP");
			}
			catch (e) {}
		}
	}
	else
		return false;

	return httpObject;
}

