var Xobj=false;
var currentText=null;
if (window.XMLHttpRequest)
{
Xobj=new XMLHttpRequest();
}
else
{
if (window.ActiveXObject)
{
Xobj=new ActiveXObject("Microsoft.XMLHTTP");
}
}

function getData(dataSource, divID,param)
{
//alert("param="+param);
//alert("source="+dataSource);
//get text from datasource and puts the text/html returned in divID
if (Xobj)
{
var obj=document.getElementById(divID);
Xobj.open("GET",dataSource);
Xobj.onreadystatechange=function()
{
if (Xobj.readyState==4 && Xobj.status==200)
{
obj.innerHTML=Xobj.responseText;

}
}

Xobj.send(param);
}


}
function getData2(dataSource)
{
//get text from datasource and puts the text/html returned in variable
var curtext=null;
if (Xobj)
{
//var obj=document.getElementById(divID);
Xobj.open("GET",dataSource);
Xobj.onreadystatechange=function()
{
if (Xobj.readyState==4 && Xobj.status==200)
{
//obj.innerHTML=Xobj.responseText;
curtext=Xobj.responseText;

}
}
Xobj.send(null);
}

return curtext;
}

function setText(mytext,divID)
{
//places text inside a divID setText("mytext","myDivID");
var obj=document.getElementById(divID);
obj.innerHTML=mytext;

}



