

////////////// email check validation ///////////////





///////////////////////// the  end /////////////////////



///////////////////////// get data from table with client id /////////////////////



function checkclientid2(cid2)

{ 

	///document.getElementById("checkid2").innerHTML = ' Fetching data...';
	document.getElementById("checkid2").innerHTML="<center><table border=0><tr><td height='250' valign='middle'><img src='http://www.ncrypted.net/images/ajax-loader.gif'></td></tr></table></center>";
	//alert(a);
	xmlHttp=GetXmlHttpObject()

	if (xmlHttp==null)

	{

	alert ("Browser does not support HTTP Request")

	return

	} 

	var url="checkclientid1.php"

	url=url+"?q="+cid2

	url=url+"&sid="+Math.random()

	xmlHttp.onreadystatechange=checkclientvalidid2

	xmlHttp.open("GET",url,true)

	xmlHttp.send(null)

}

function checkclientvalidid2() 

{ 

	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")

	{ 

		document.getElementById("checkid2").innerHTML=xmlHttp.responseText

		che_arr();

	} 

}

////////////////////////// the end /////////////////

 

/////////////////////    FORGOT Client id  /////////////////////////////////



function forgotid2(fcid2)

{ 
	
	document.getElementById("forgotemail2").innerHTML="<center><table border=0><tr><td height='250' valign='middle'><img src='http://www.ncrypted.net/images/ajax-loader.gif'></td></tr></table></center>";
	xmlHttp=GetXmlHttpObject()

	if (xmlHttp==null)

	{

	alert ("Browser does not support HTTP Request")

	return

	} 

	var url="forgotemail1.php"

	url=url+"?q="+fcid2

	url=url+"&sid="+Math.random()

	xmlHttp.onreadystatechange=forgotvalidid2

	xmlHttp.open("GET",url,true)

	xmlHttp.send(null)

}

function forgotvalidid2() 

{ 

	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")

	{ 

		document.getElementById("forgotemail2").innerHTML=xmlHttp.responseText

	} 

}

///////////////////////         THE END     forgot    Client id  ///////////////////////////////



//////////////////////////    edit clietn id //////////////////////////



function editcid2(uid,fname,lname,company,address,city,country,phone,website,comments,inquiry)

{ 

	xmlHttp=GetXmlHttpObject()

	if (xmlHttp==null)

	{

	alert ("Browser does not support HTTP Request")

	return

	} 

	

	var passData1 = 'fname='+escape(fname)+'&lname='+escape(lname)+'&company='+escape(company)

	+'&city='+escape(city)+'&country='+escape(country)

	+'&address='+escape(address)+'&phone='+escape(phone)+'&website='+escape(website)+'&comments='+escape(comments)

	+'&uid='+escape(uid)+'&inquiry='+escape(inquiry);

	xmlHttp.onreadystatechange=editclientvalidid2

	xmlHttp.open("POST","edit_clientid1.php",true)

	xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");

	xmlHttp.send(passData1);

	

}

function editclientvalidid2() 

{ 

	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")

	{ 

		document.getElementById("editid2").innerHTML=xmlHttp.responseText

		

	

		var prod3=document.getElementsByName('pro2[]');

			

			for(var i=0;i<prod3.length;i++)

			{

				if(prod3[i].checked)

				{

					city1[i]=0;

					city1[i]=prod3[i].value;

				}

			}

	} 

}

////////////////////////// the end cld ///////////////////////////



function GetXmlHttpObject()

{ 

	var objXMLHttp=null

	if (window.XMLHttpRequest)

	{

		objXMLHttp=new XMLHttpRequest()

	}

	else if (window.ActiveXObject)

	{

		objXMLHttp=new ActiveXObject("Microsoft.XMLHTTP")

	}

	return objXMLHttp

}