function create_xml_object()
{
	var newobj=false;
	/*@cc_on @*/
	/*@if (@_jscript_version >= 5)
	// JScript gives us Conditional compilation, we can cope with old IE versions.
	// and security blocked creation of the objects.
 	try
	{
  		newobj = new ActiveXObject("Msxml2.XMLHTTP");
 	}
	catch(e)
	{
  		try
		{
   			newobj = new ActiveXObject("Microsoft.XMLHTTP");
  		}
		catch(E)
		{
   			newobj = false;
  		}
 	}
	@end @*/
	if (!newobj && typeof XMLHttpRequest!='undefined')
	{
  		newobj = new XMLHttpRequest();
	}

	return newobj;
}


function doRequest(xmlobj, method, url, async, callbackfunc, postdata)
{
	xmlobj.abort();

	if(async)
		xmlobj.onreadystatechange = callbackfunc;

	xmlobj.open(method, url, async);
	
	if(method.toUpperCase() == 'POST')
	{
		xmlobj.setRequestHeader('Content-Type','application/x-www-form-urlencoded');
		xmlobj.send(postdata);
	}
	else
	{
		xmlobj.send(null);	
	}
	
	return false;
}