//*************************************************************************************************
//The purpose of the function is to solve the problem of creating different XMLHTTP objects 
//for different browsers. 
//**************************************************************************************************

 //window.onload=refresh;
 function refresh()
 {
	if(history.length>0)
	{
	  document.Form2.FrstName.value="";
	  document.Form2.LstName.value="";
	  document.Form2.eml.value="";
	  document.Form2.txtsecurity.value="";
	}
 }

function GetXmlHttpObject()
{
var xmlHttp=null;
try
  {
  // Firefox, Opera 8.0+, Safari
  xmlHttp=new XMLHttpRequest();
  }
catch (e)
  {
  // Internet Explorer
  try
    {
    xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
    }
  catch (e)
    {
    xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
    }
  }
return xmlHttp;
}

//**************************************************************************************************

//**************************************************************************************************
//This for genearte Randome text for image
//This function executes every time the state of the XMLHTTP object changes.
//When the state changes to 4 ("complete"), made changes according to response.
//**************************************************************************************************
function stateChanged() 
{ 

	if (xmlHttp.readyState==4)
	{ 
	  document.getElementById('imgvrif').innerHTML= document.getElementById('imgvrif').innerHTML + xmlHttp.responseText;
	}
	
}
//*************************************************************************************************

 function Getdata()
{
   
   xmlHttp=GetXmlHttpObject();

	var url="checkdate.asp";
	xmlHttp.onreadystatechange=stateChanged;
	xmlHttp.open("GET",url,true);
	xmlHttp.send(null);

	}

