// JavaScript Document
var divid="";

function CreateXmlHttp()
{
    //Creating object of XMLHTTP in IE
    try
    {
        XmlHttp = new ActiveXObject("Msxml2.XMLHTTP");
    }
    catch(e)
    {
        try
        {
            XmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
        }
        catch(e)
        {
            XmlHttp = null;
        }
    }
    //Creating object of XMLHTTP in Mozilla and Safari
    if(!XmlHttp && typeof XMLHttpRequest != "undefined")
    {
        XmlHttp = new XMLHttpRequest();
    }
}

function HandleResponse()
{	
    if(XmlHttp.readyState == 2){
		//alert('sdafasdfds');
		document.getElementById(divid).innerHTML = '<span class="loadingText" style="padding-left:10px;padding-right:10px;">Loading...</span>';	
	}
	if(XmlHttp.readyState == 4)
    {
        if(XmlHttp.status == 200)
        {  //alert(divid);
            document.getElementById(divid).innerHTML=XmlHttp.responseText
        }
        else
        {
            alert("There was a problem retrieving data from the server." );
        }
    }
}
