function Ajax()
{
	try
	{
		this.xmlHttp = new XMLHttpRequest();
	}
	catch (e)
	{
		try
		{
			this.xmlHttp = new ActiveXObject('Msxml2.XMLHTTP');
		}
		catch (e)
		{
			try
			{
				this.xmlHttp = new ActiveXObject('Microsoft.XMLHTTP')
			}
			catch (e)
			{
				// AJAX incompatible
				this.xmlHttp = false;
			}
		}
	}
	
	ajaxobj = this;
	
	this.xmlHttp.onreadystatechange = function()
	{
		if (ajaxobj.xmlHttp.readyState==4)
		{                             
			ajaxobj.callback(ajaxobj.xmlHttp.responseText, ajaxobj.xmlHttp.status, ajaxobj.xmlHttp.responseXML);                                                 
        } 
	}
	
	this.callback = function () {};
	
	this.get = function(uri)
	{
		this.xmlHttp.open('GET', uri, true);
		this.xmlHttp.send(null);
	}
	
	this.post = function(uri, params)
	{
		this.xmlHttp.open('POST', uri, true);
		this.xmlHttp.setRequestHeader('Content-type', 'application/x-www-form-urlencoded');
		this.xmlHttp.setRequestHeader('Content-length', params.length);
		this.xmlHttp.setRequestHeader('Connection', 'close');
		this.xmlHttp.send(params);
	}
}