var xmlHttp;
function createXMLHttpRequest()
{
	try
	{
		req = new ActiveXObject("Msxml2.XMLHTTP");
		usewin = "msxml";
	}
	catch(e)
	{
		try
		{
			req = new ActiveXObject("Microsoft.XMLHTTP");
			usewin = "microsoft";
		}
		catch(e)
		{
			req = null;
		}
	}
	if(!req && typeof XMLHttpRequest != "undefined")
	{
		req = new XMLHttpRequest();
		usewin = "undefined";
	}
	return req;
}
function startRequestx(xmlUrl,htmObj)
{
	xmlUrl += "&randomtemp=" + Math.random();
	document.getElementById(htmObj).innerHTML = "<img src='/images/load.gif' border='0'>";
	setTimeout("RequsetBeginx('" + xmlUrl + "', '" + htmObj + "')",1000);
}
function RequsetBeginx(xmlUrl, htmObj)
{
	/// alert(xmlUrl);
	var req = createXMLHttpRequest();
	try
	{
		if(req != null)
		{
			var handleResponse = handleStateChangex(req, htmObj);
			req.onreadystatechange = handleResponse;
			req.open("get", xmlUrl, true);
			req.send(null);
		}
	}
	catch(e)
	{
		alert('Request send failed.' + e.message);
	}
	finally
	{
	}	
}
function handleStateChangex(req,htmObj)
{
	return function()
	{
		try
		{
			if(req.readyState == 4)
			{
				if(req.status == 200)
				{
					switch(req.responseText)
					{
						case null:
						case "":
						break;
						default:
							document.getElementById(htmObj).innerHTML = req.responseText;
						break;
					}
				}
			}
		}
		catch(e)
		{
			alert('Response failed.' + e.message);
		}
		finally
		{
		}
	}
}