/*

/*/// <summary>

///*********************************************************************************

/// MAIN MODULE:              Accura tech payment gateway web site

/// SUB MODULE :              scripts

/// AUTHOR:                   Hansaka Wijewardana

/// CREATED:                  09-Mar-2007

/// DESCRIPTION:              This AJAX module developed to check whether the user has paid for search all jobseekers 

/// MODIFICATION HISTORY:     1.0     22-Mar-2007       Initial Version

/// COPYRIGHT:                Copyright accura-tech.com. All Rights Reserved

/// ********************************************************************************

/// </summary> 

///

function search_lookup(str)
{
	var id = document.forms["search"].type.selectedIndex;
	if(id==1)
	showHint1(str);
}

function showHint1(str)
{
xmlHttp=GetXmlHttpObject1();
if (xmlHttp==null)
  {
  alert ("Your browser does not support AJAX!");
  return;
  }        
var url="search_allow.php";

xmlHttp.onreadystatechange=stateChanged1;
xmlHttp.open("GET",url,true);
xmlHttp.send(null);
} 

function stateChanged1() 
{ 
if (xmlHttp.readyState==4)
   { 
   var result = xmlHttp.responseText;
   if(result=="valid")
   var res = "do nothing";
   else
   window.location.href="search_pay.php";
   }
}

function GetXmlHttpObject1()
{
var xmlHttp=null
if (window.XMLHttpRequest)
{
xmlHttp=new XMLHttpRequest()
}
else if (window.ActiveXObject)
{
xmlHttp=new ActiveXObject("Microsoft.XMLHTTP")
}
return xmlHttp
}