// JavaScript Document















var xmlHttp







function GetXmlHttpObject()


{ 







var objXMLHttp=null







if (window.XMLHttpRequest)







{







objXMLHttp=new XMLHttpRequest()







}







else if (window.ActiveXObject)







{







objXMLHttp=new ActiveXObject("Microsoft.XMLHTTP")







}







return objXMLHttp







}















function state_cont()
{	

	contry=document.getElementById('committee_country').value;

document.getElementById('committee_city').length=1;

document.getElementById('committee_locality').length=1;
	 xmlHttp=GetXmlHttpObject()
			if (xmlHttp==null)
			{
			alert ("Browser does not support HTTP Request")
			return
			} 
			var url="show_ajax.php?c="+contry+"&s=state";		
			//window.location=url;
			xmlHttp.onreadystatechange=function()
			{
				document.getElementById('committee_state').length=1;
		if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
			{ 
					mearray=xmlHttp.responseText.split("[]");

			for (i=0;i<mearray.length-1;i++)







				{					







					if(mearray[i]!="")







					{







							valcat=mearray[i].split("{}");







							oOption = document.createElement("Option");







							oOption.text = valcat[1];







							oOption.value = valcat[0];







							document.getElementById('committee_state').options.add(oOption);							







						}						







					}







				}







			}







			







			xmlHttp.open("GET",url,true)







			xmlHttp.send(null)		







			







}

function city_state()
{

	state=document.getElementById('committee_state').value;
	document.getElementById('committee_locality').length=1;
	 xmlHttp=GetXmlHttpObject()
			if (xmlHttp==null)
			{
			alert ("Browser does not support HTTP Request")
			return
			} 
			var url="show_ajax.php?c="+state+"&s=city";		
			//window.location=url;
			xmlHttp.onreadystatechange=function()
			{
				document.getElementById('committee_city').length=1;
		if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
			{ 
					mearray=xmlHttp.responseText.split("[]");
			for (i=0;i<mearray.length-1;i++)
				{					
					if(mearray[i]!="")
					{

							valcat=mearray[i].split("{}");
							oOption = document.createElement("Option");







							oOption.text = valcat[1];







							oOption.value = valcat[0];







							document.getElementById('committee_city').options.add(oOption);							







						}						







					}







				}







			}







			







			xmlHttp.open("GET",url,true)







			xmlHttp.send(null)					







}























function local()







{







	







	city=document.getElementById('committee_city').value;







	 xmlHttp=GetXmlHttpObject()







			if (xmlHttp==null)







			{







			alert ("Browser does not support HTTP Request")







			return







			} 







			var url="show_ajax.php?c="+city+"&s=zone";		







			//window.location=url;







			xmlHttp.onreadystatechange=function()







			{







				document.getElementById('committee_locality').length=1;







		if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")







			{ 







					mearray=xmlHttp.responseText.split("[]");







					sma=0;







			for (i=0;i<mearray.length-1;i++)







				{					







					if(mearray[i]!="")







					{







							valcat=mearray[i].split("{}");







							oOption = document.createElement("Option");







							//oOption.text =valcat[1];







							//oOption.value = valcat[0];







							oOption.style.color='#000000';







							oOption.style.backgroundColor='gray';







							ooOption = document.createElement("Option");







							ooOption.text = valcat[1];







							ooOption.value = valcat[0];







							/*if(oOption.value!=sma)







							{







							  sma=oOption.value;







							  document.getElementById('committee_locality').options.add(oOption);		







							}*/







	document.getElementById('committee_locality').options.add(ooOption);	







						}						







					}







				}







			}







			







			xmlHttp.open("GET",url,true)







			xmlHttp.send(null)					







}























function pin()
{
	city=document.getElementById('committee_locality').value;
	
	 xmlHttp=GetXmlHttpObject()

			if (xmlHttp==null)

			{

			alert ("Browser does not support HTTP Request")
			return

			} 

			var url="show_ajax.php?c="+city+"&s=pin";		

			//window.location=url;
			xmlHttp.onreadystatechange=function()

			{


		if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")







			{ 







					mearray=xmlHttp.responseText.split("[]");







					sma=0;







			for (i=0;i<mearray.length-1;i++)







				{					







					if(mearray[i]!="")
					{
							valcat=mearray[i].split("{}");
	document.getElementById('regpin').innerHTML=valcat[1];
	document.getElementById('committee_pin').value=valcat[1];
		document.getElementById('committee_pin').value=valcat[1];
		//committee_pin
						}						







					}







				}







			}







			







			xmlHttp.open("GET",url,true)







			xmlHttp.send(null)					







}



















var faq="";



var qu="";



function poll_submit(quesno)







{







	var poll_res='';







	for(k=1;k<quesno;k++)







	{	







		var poll_op=document.getElementsByName('radio'+k);







		







		for(i=0;i<poll_op.length;i++)







		{	m=1;		







			if(poll_op[i].checked==true)







			{







				var poll_res=poll_op[i].value+','+poll_res;					







			}				







		}







	}







	 if(poll_res!="")







			 {







	 xmlHttp=GetXmlHttpObject()







			if (xmlHttp==null)







			{







			alert ("Browser does not support HTTP Request")







			return







			} 







			var url="show_ajax.php?c="+poll_res+"&s=poll";		







			//window.location=url;			



document.getElementById('pollshow').innerHTML="";



document.getElementById('pollshow').style.display="";







			xmlHttp.onreadystatechange=function()







			{







				







		if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")







			{ 







					mearray=xmlHttp.responseText.split("[]");



					



		for (i=0;i<mearray.length-1;i++)



				{	



				valcat=mearray[i].split("{}");



if (valcat[0]==qu){faq="";} else { faq=valcat[0]; }



	drawPercentBar(100, valcat[2], 'red');



					}



			document.getElementById('pollshow').innerHTML=document.getElementById('pollshow').innerHTML+"<br><a href=# onClick=hie()><b>Close</b></a>";







			}







			}







			xmlHttp.open("GET",url,true)







			xmlHttp.send(null)				







			alert("Your Poll Is submited successfully..... Thank you");







	poll_cancel(quesno);















 }







 else







 {







	 		alert("Please Select any option..... Thank you");







 }







}















 function drawPercentBar(width, percent, color, background) 



  { 



  



    var pixels = width * (percent / 100); 



    if (!background) { background = "none"; }



	qu=valcat[0];



	  var ght=("<b>"+faq+"</b><br>"+valcat[1]+"<div style=\"position: relative; line-height: 1em; background-color: " + background + "; border: 1px solid black; width: " + width + "px\"><div style=\"height: 1.5em; width: " + pixels + "px; background-color: "+ color + ";\"></div><div style=\"position: absolute; text-align: center; padding-top: .25em; width: " + width + "px; top: 0; left: 0\">" + percent + "%</div></div>");



	var fgh=ght;



	document.getElementById('pollshow').innerHTML=document.getElementById('pollshow').innerHTML+"<br>"+fgh;



  } 







function hie()



	{



document.getElementById('pollshow').style.display="none";	



	}







function poll_cancel(quesno)







{







for(k=1;k<quesno;k++)







	{	







	var poll_op=document.getElementsByName('radio'+k);		







		for(i=0;i<poll_op.length;i++)







		{		







			poll_op[i].checked=false;







		}







	}	







}











/* function poll_show(quesno)



{



var ques=quesno.split("{}");



		for (i=0;i<ques.length-1;i++)



				{		







				var qu=ques[i];



				alert(qu);



				document.getElementById('pollshow').innerHTML=document.getElementById('pollshow').innerHTML+"<br>"+qu;



				}



	}







*/







    







	















 function  search_all(frm)
 {
	 	
		//alert('srch action called..');
		name=document.getElementById('name').value;

		type=document.getElementById('type').value;

		locality=document.getElementById('locality').value;

		pin=document.getElementById('pin').value;

		

		if (name=="--By Name--" && type=="" && locality=="" && pin=="")

		{

			alert("Please select or enter the Name/Puja Type/Locality/Pin ... thank you!!");

			return false();

		}else{

		 xmlHttp=GetXmlHttpObject()

			if (xmlHttp==null)

			{

			alert ("Browser does not support HTTP Request")

			return false();

			} 

			var url="search.php?name="+name+"&type="+type+"&locality="+locality+"&pin="+pin+"&cms=15";	

			window.location=url;			

			xmlHttp.open("GET",url,true)

			xmlHttp.send(null)		

		}

 }







 







function  search_alll()
 {



	//alert('srch action called..1');



		name=document.getElementById('name').value;







		type=document.getElementById('type').value;







		locality=document.getElementById('locality').value;







		pin=document.getElementById('pin').value;	







		if (name=="--By Name--" && type=="" && locality=="" && pin=="")







		{







			alert("Please select or enter the Name/Puja Type/Locality/Pin ... thank you!!");







			return false;







		}else {







			return true







			







		 xmlHttp=GetXmlHttpObject()







			if (xmlHttp==null)







			{







			alert ("Browser does not support HTTP Request")







			return







			} 







			var url="search.php?name="+name+"&type="+type+"&locality="+locality+"&pin="+pin+"&cms=15";	







			window.location=url;			







			xmlHttp.open("GET",url,true)







			xmlHttp.send(null)		







		}







			







 }







 







function register_cancel()
{


//document.getElementById('kdpregister').reset();

//document.getElementById('committee_cat').lenth=1;



document.getElementById('committee_country').lenth=1;







document.getElementById('committee_state').lenth=1;	







document.getElementById('committee_city').lenth=1;







document.getElementById('committee_userid').value="";







document.getElementById('committee_pass').value="";







document.getElementById('committee_name').value="";







document.getElementById('committee_renowned').value="";







document.getElementById('committee_address').value="";







document.getElementById('committee_pin').value="";















}















function register_submit()
{
	var whitespace=new RegExp(/^\s+$/);


if (document.getElementById('committee_cat').value=="")
{
 alert("Please select committee category....");
 document.getElementById('committee_cat').focus();
 return false;
}

if (document.getElementById('committee_name').value=="" || whitespace.test(document.getElementById('committee_name').value))
{
 alert("Please enter Committee Name");
 document.getElementById('committee_name').focus();
 return false;
}



if (document.getElementById('committee_address').value=="" || whitespace.test(document.getElementById('committee_address').value))
{
 alert("Please enter Committee Address");
 document.getElementById('committee_address').focus();
 return false;
}


//if(document.getElementById('reg_country').style.display=='block'){
	
	//alert("def country...");
				/*if (document.getElementById('committee_country').value=="")
				{
				
				 alert("Please enter Committee Country **");
				 document.getElementById('committee_country').focus();
				 return false;
				
				}*/

	if(document.getElementById('reg_country').style.display=='block'){
			
			if ($('committee_country').value=="")
			{
			 alert("Please enter Committee country");
			 $('committee_country').focus();
			 return false;
			}
	}
	if($('show_country').style.display=='block'){
			alert('hid country***');
		if(whitespace.test($('committee_country_p').value)){
					alert("Please enter Committee Country...");
				 $('committee_country_p').focus();
				 return false;
				}
		
		return false;
	}


//}
/*if(document.getElementById('show_country').style.display=='block')
//{
	
	//alert('prob country');
				if(whitespace.test(document.getElementById('committee_country_p').value)){
					alert("Please enter Committee Country...");
				 document.getElementById('committee_country_p').focus();
				 return false;
				}
//}

			if(document.getElementById('show_country_text').style.display=='block' )
			{
				if(whitespace.test(document.getElementById('committee_country_p').value)){
					alert("Please enter Committee Country...");
				 document.getElementById('committee_country_p').focus();
				 return false;
				}
			}
			else{
				if (document.getElementById('committee_country').value=="")
				{
				
				 alert("Please enter Committee Country **");
				 document.getElementById('committee_country').focus();
				 return false;
				
				}
			}

*/

if (document.getElementById('committee_state').value=="")
{
 alert("Please enter Committee State");
 document.getElementById('committee_state').focus();
 return false;
}
			/*if(document.getElementById('show_state_text').style.display=='block'  && whitespace.test(document.getElementById('committee_state_p').value))
			{
					alert("Please enter Committee State...");
				 document.getElementById('committee_state_p').focus();
				 return false;
			}*/



if (document.getElementById('committee_city').value=="")
{
 alert("Please enter Committee City");
 document.getElementById('committee_city').focus();
 return false;
}
			/*if(document.getElementById('show_city_text').style.display=='block'  && whitespace.test(document.getElementById('committee_city_p').value))
			{
					alert("Please enter Committee City");
				 document.getElementById('committee_city_p').focus();
				 return false;
			}*/

if (document.getElementById('committee_locality').value=="")
{
 alert("Please enter Committee Locality");
 document.getElementById('committee_locality').focus();
 return false;
}
			/*if(document.getElementById('show_locality_text').style.display=='block'  && whitespace.test(document.getElementById('committee_locality_p').value))
			{
					alert("Please enter Committee Locality");
				 document.getElementById('committee_locality_p').focus();
				 return false;
			}*/


			if(whitespace.test(document.getElementById('committee_pin').value))
			{
				alert("Please enter Committee Pin");
				 document.getElementById('committee_pin').focus();
				 return false;
			}


if (document.getElementById('committee_contph').value=="" || whitespace.test(document.getElementById('committee_contph').value))
{
 alert("Please enter phone number!");
 document.getElementById('committee_contph').focus();
 return false;
}

if (document.getElementById('committee_contph').value!="" && isNaN(document.getElementById('committee_contph').value)){

 alert("Please enter phone number properly!");

 document.getElementById('committee_contph').focus();

 return false;
}

if (document.getElementById('committee_mob').value!="" && isNaN(document.getElementById('committee_mob').value)){

 alert("Please enter mobile number properly!");

 document.getElementById('committee_mob').focus();

 return false;
}

var oRegX = new RegExp(/^[0-9a-z_]+$/gi);

var oRegXEmail = new RegExp(/^[\w_-]+(\.[\w_-]+)*@[\w_-]+(\.[\w_-]+)*\.\w{2,4}$/gi);

var oRegXConEmail = new RegExp(/^[\w_-]+(\.[\w_-]+)*@[\w_-]+(\.[\w_-]+)*\.\w{2,4}$/gi);



if (document.getElementById('committee_email').value==""  || whitespace.test(document.getElementById('committee_email').value))

{

 alert("Please enter Committee Email");

 document.getElementById('committee_email').focus();

 return false;

}

if(!oRegXEmail.test(document.getElementById('committee_email').value))

{

 alert("Incorrect email address format. Please type a valid email address");

 document.getElementById('committee_email').focus();

 return false;

}



if ((document.getElementById('committee_year').value=="") || (document.getElementById('committee_year').value.length<4 ) )
{

 alert("Please enter minimum 4 digit number in year");

 document.getElementById('committee_year').focus();

 return false;

}

if ((document.getElementById('committee_year').value!="") && isNaN(document.getElementById('committee_year').value))
{
		//alert('year value check...');
 alert("Please enter minimum 4 digit number in year");
 document.getElementById('committee_year').focus();
 return false;
}


if (document.getElementById('committee_userid').value=="" || whitespace.test(document.getElementById('committee_userid').value))
{
	alert("Please enter Committee User Name");
	document.getElementById('committee_userid').focus();

return false;
}


if (document.getElementById('committee_pass').value=="" || whitespace.test(document.getElementById('committee_pass').value))
{

alert("Please enter Password");

	document.getElementById('committee_pass').focus();

return false;

}



if(document.getElementById("committee_pass").value!=document.getElementById("pass").value)
{

  alert("Please confirm your Password ");

  document.getElementById("pass").focus();

  return false;

}

if (document.getElementById('committee_chairman').value=="" || whitespace.test(document.getElementById('committee_chairman').value))

{

 alert("Please enter Chairman's Name");

 document.getElementById('committee_chairman').focus();

 return false;

}



if (document.getElementById('committee_president').value=="")

{

 alert("Please enter President's Name");

 document.getElementById('committee_president').focus();

 return false;

}



if (document.getElementById('committee_secretary').value=="")

{

 alert("Please enter Secretary's Name");

 document.getElementById('committee_secretary').focus();

 return false;

}



if (document.getElementById('committee_submited').value=="")

{

 alert("Please enter Submited By");

 document.getElementById('committee_submited').focus();

 return false;

}


/*
if (document.getElementById('descrip').value=="")
{
 alert("Please enter Description");

 document.getElementById('descrip').focus();

 return false;
}
*/

/*if (document.getElementById('fileupload1').value=="")
{
 alert("Please upload an image");

 document.getElementById('fileupload1').focus();

 return false;
}*/



if (document.getElementById('code').value=="")
{
 alert("Please enter security code");
 document.getElementById('code').focus();
 return false;
}



/*

if (document.getElementById('committee_contph').value=="")

{

 alert("Please enter Committee Phone");

 document.getElementById('committee_contph').focus();

 return false;

}



if (document.getElementById('committee_mob').value=="")

{

 alert("Please enter Committee Mobile");

 document.getElementById('committee_mob').focus();

 return false;

}

*/

return true;

}


function checkMobileNumber()
{
		//alert('check input number...');
	var mobile_input=document.getElementById('divmob').value;
		if(isNaN(mobile_input))
		{
			document.getElementById('divmob').value='';
			alert('Please enter mobile number properly!');
		}
}

function close_pop()
{
		//alert('close pop...');
	document.getElementById('avbl').style.display="none";
	/*if(document.getElementById('avbl').style.display=="block")
	{
		document.getElementById('avbl').style.display="none";
	}*/
}


function com_match()
{		
		var committee_name=document.getElementById('committee_name').value;
		var comit_cat=document.getElementById('committee_cat').value;
			
			//alert('commit cat: '+comit_cat);
	if(committee_name=="")
	{
			document.getElementById('avbl').style.display="none";	
	}
	else
	{
			document.getElementById('avbl').style.display="";	
			document.getElementById("avbl").innerHTML="<img src=images/loading.gif />";
	}
			xmlHttp=GetXmlHttpObject()
			if (xmlHttp==null)
			{
				alert ("Browser does not support HTTP Request")
				return
			} 
			var url="chk_user.php?committee_name="+committee_name+"&commit_cat="+comit_cat;		
		//	window.location=url;
			xmlHttp.onreadystatechange=function()
			{
				if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
				{ 
					mearray=xmlHttp.responseText;
				//element = document.getElementById('avbl');
				//document.getElementsByName("avbl").innerHTML=mearray;
				//alert(element);
				  document.getElementById('avbl').innerHTML = mearray;

				}

			}
			xmlHttp.open("GET",url,true)

			xmlHttp.send(null)		

}



function validate_chk()
{		
			//alert('validate div check...');
			
				var	count=0;	
				var usr_op=document.getElementsByName('chk');			
					//alert("Total check "+usr_op.length);
				for(var i=0;i<usr_op.length;i++)
				{
					//alert('enter name chk...');
					if (usr_op[i].checked=="checked")
					{
						count=1;
						alert('enter name chk...found..');
					}
				}
				if (count==0)
				{
					alert("Please Select any option thank you...");
					return false;
				}
else
{
				if (document.getElementById('divname').value=="")
				{
					alert("Please enter  your Name... ");
					document.getElementById('divname').focus();
				return false;
				}	
		oRegX = new RegExp(/^[0-9a-z_]+$/gi);
		oRegXEmail = new RegExp(/^[\w_-]+(\.[\w_-]+)*@[\w_-]+(\.[\w_-]+)*\.\w{2,4}$/gi);
		oRegXConEmail = new RegExp(/^[\w_-]+(\.[\w_-]+)*@[\w_-]+(\.[\w_-]+)*\.\w{2,4}$/gi);

	if (document.getElementById('divemail').value=="")
	{
		alert("Please enter  Email");
		document.getElementById('divemail').focus();
		return false;
	}
	if(!oRegXEmail.test(document.getElementById('divemail').value))
		{
			alert("Incorrect email address format. Please type a valid email address.");
			document.getElementById('divemail').focus();
			return false;
		}
	if (document.getElementById('divmob').value=="")
	{
		alert("Please enter  Mobile No");
			document.getElementById('divmob').focus();
		return false;
	}
		return true;
}

}

function commit_pop_validation()
{
		//alert('div commit pop!..');
				var	count=0;
				var flag=true;
				//var str='frm_com_pop';;
				var usr_op=document.getElementsByName('chk[]');			
				   //var elem=document.elements.length;
				   //alert('user check..'+usr_op.checked+' '+usr_op.length);
				   
				if (document.getElementById('divname').value=="") 
				{
					alert("Please enter  your Name.. ");
					document.getElementById('divname').focus();
				return false;
				}	
				oRegX = new RegExp(/^[0-9a-z_]+$/gi);
				oRegXEmail = new RegExp(/^[\w_-]+(\.[\w_-]+)*@[\w_-]+(\.[\w_-]+)*\.\w{2,4}$/gi);
				oRegXConEmail = new RegExp(/^[\w_-]+(\.[\w_-]+)*@[\w_-]+(\.[\w_-]+)*\.\w{2,4}$/gi);

	if (document.getElementById('divemail').value=="")
	{
		alert("Please enter  Email");
		document.getElementById('divemail').focus();
		return false;
	}
	else if(!oRegXEmail.test(document.getElementById('divemail').value))
		{
			alert("Incorrect email address format. Please type a valid email address.");
			document.getElementById('divemail').focus();
			return false;
		}
	else if (document.getElementById('divmob').value=="")
	{
			alert("Please enter  Mobile No");
			document.getElementById('divmob').focus();
			return false;
	}
				   
	else
	{
			//document.frm_com_pop.submit();
			//alert('pass validation!');
				   for (var i = 0; i < usr_op.length-1; i++) 
				   {
							//alert('checked...'+usr_op[i].checked);
						if(usr_op[i].checked==false)
						{
							//alert("Please checked committee.. ");
							flag=false;
						}
						if(usr_op[i].checked==true)
						{
							flag=true;
							break;
						}
				   }
				   		if(!flag)
						{
							alert("Please select committee properly! ");
							return false;
						}
						else
						{
							top.location.href='user_thank.php?divname='+document.getElementById('divname').value+'&divmob='+document.getElementById('divmob').value+'&divemail='+document.getElementById('divemail').value+'&chk='+document.getElementById('chk').value+'&cms='+document.getElementById('cms').value+'&divdesig='+document.getElementById('divdesig').value;
							return true;
						}
	}
}



function valid_user()

{		
	//alert("calling....commitee....");



if (document.getElementById('comuser').value=="Committee Name" || document.getElementById('comuser').value=="")


{


alert("Please enter  Committee Name");


	document.getElementById('comuser').focus();







return false;

}

if (document.getElementById('compass').value=="Password" || document.getElementById('compass').value=="" )

{

alert("Please enter  Password");

	document.getElementById('compass').focus();

return false;

}

if (document.getElementById('comuser').value!="Committee Name" || document.getElementById('comuser').value!="" && document.getElementById('compass').value!="Password" || document.getElementById('compass').value!="" )

{

 			xmlHttp=GetXmlHttpObject()

			if (xmlHttp==null)

			{

			alert ("Browser does not support HTTP Request")

			return
			} 

			var url="show_ajax.php?usr="+document.getElementById('comuser').value+"&s=login_user&pwd="+document.getElementById('compass').value;				

			//window.location=url;			

			xmlHttp.onreadystatechange=function()

			{

				if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")

				{
						mearray=xmlHttp.responseText.split(",");						

					if(mearray[1]==0)

					{

						alert("Incorrect Committee Name or password");

					}

					else if (mearray[0]!="")

					{
					var url="commitee_profile.php?usr="+mearray[0]+"&cms=17";

					window.location=url;
					}

				}
		}


			xmlHttp.open("GET",url,true)

			xmlHttp.send(null)	

return false;

}

//return true;


}

function redirect_url()
{

var url="index.php?cms=14";

window.location=url;
}


function com_user()
{	

		var email=document.getElementById('committee_userid').value;	
		
		if(email=="")
		{
			document.getElementById('avbl_user').style.display="none";	
		}else
		{
			document.getElementById('avbl_user').style.display="";	
			element = document.getElementById("avbl_user").innerHTML="<img src=images/loading.gif />";
		}
			xmlHttp=GetXmlHttpObject()
			if (xmlHttp==null)
			{
			alert ("Browser does not support HTTP Request")
			return
			} 
			var url="chk_user_name.php?email="+email;		
			//window.location=url;
			xmlHttp.onreadystatechange=function()
			{
				if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
				{ 
					mearray=xmlHttp.responseText;
				element = document.getElementById("avbl_user");
				  element.innerHTML = mearray;
				}
			}
			xmlHttp.open("GET",url,true)
			xmlHttp.send(null)		
}




















function chgyr_usr_view_about_puja(user)
{
			//alert('calling..user_view More Details Of Puja...');
			
		document.getElementById("show_about_puja").innerHTML='<p align="center"><img src="images/loader.gif"></p>';
			
			var year=document.getElementById('year2').value;	
			
			
			//alert('calling ajax award...');
		 		xmlHttp=GetXmlHttpObject()
			if (xmlHttp==null)
			{
			alert ("Browser does not support HTTP Request")
			return
			} 

			//var url="showyrdiv_1.php?year="+yea+"&comid="+user;		

			var url="showyrdiv_commit_user_puja_detls.php?year="+year+"&comid="+user;
			//window.location=url;
			xmlHttp.onreadystatechange=function()
			{
				if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
				{ 
				   
				    //alert('ajax Response: '+xmlHttp.responseText);

					document.getElementById("show_about_puja").innerHTML=xmlHttp.responseText;

					//mearray=xmlHttp.responseText.split("[]");

					//alert(mearray);
			/*for (i=0;i<mearray.length-1;i++)
			{					
				if(mearray[i]!="")
				{
					valcat=mearray[i].split("{}");
					document.getElementById("awgali").innerHTML= valcat[0];	
					document.getElementById("awgaln").innerHTML= valcat[1];
				    document.getElementById("awgalc").innerHTML= valcat[2];
					document.getElementById("awgalp").innerHTML= valcat[3];		
					var g=('<img src="thumb_gallery/'+valcat[4]+'">');
					document.getElementById("awgali").innerHTML=g;
						}	
			}*/
			}
			}
			xmlHttp.open("GET",url,true)
			xmlHttp.send(null)	 
}








//document.getElementById('year').value;
function chgyr(user)
{

////  This is called user individual admin section ajax puja details

		document.getElementById("ajax_loader").style.display='block';
		document.getElementById("ajax_loader").innerHTML='<img src="images/loader.gif">';

		var year=document.getElementById('year_abt').value;	

			//alert('user view puja year details...'+year);

		 	xmlHttp=GetXmlHttpObject()

			if (xmlHttp==null)
			{
			alert ("Browser does not support HTTP Request")

			return
			} 
			var url="showyrdiv.php?year="+year+"&comid="+user;		

			//window.location=url;

			xmlHttp.onreadystatechange=function()
			{

				if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
				{ 
					 //alert(xmlHttp.responseText.split("[]"));

					mearray=xmlHttp.responseText.split("[]");

				for (i=0;i<mearray.length-1;i++)
				{		
					if(mearray[i]!="")
					{

							valcat=mearray[i].split("{}");
							document.getElementById("ajax_loader").style.display='none';
							document.getElementById("galyr").innerHTML= valcat[0];	

							document.getElementById("galbud").innerHTML= valcat[1];

						    document.getElementById("fall").innerHTML= valcat[2];

							document.getElementById("prat").innerHTML= valcat[3];							

							document.getElementById("pand").innerHTML= valcat[4];	

							document.getElementById("elec").innerHTML= valcat[5];

						    document.getElementById("extra").innerHTML= valcat[6];

						}	
					}

				}

			}
			xmlHttp.open("GET",url,true)
			xmlHttp.send(null)	 
}

function chgyraw(user)
{
		
			document.getElementById("show_awards").innerHTML='<p align="center"><img src="images/loader.gif"></p>';
			var yea=document.getElementById('ye').value;	
			//alert('calling ajax award...');
		 		xmlHttp=GetXmlHttpObject()
			if (xmlHttp==null)
			{
			alert ("Browser does not support HTTP Request")
			return
			} 

			//var url="showyrdiv_1.php?year="+yea+"&comid="+user;		

			var url="showyrdiv_awards.php?year="+yea+"&comid="+user;
			//window.location=url;
			xmlHttp.onreadystatechange=function()
			{
				if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
				{ 
				   
				    //alert('ajax Response: '+xmlHttp.responseText);

					document.getElementById("show_awards").innerHTML=xmlHttp.responseText;

					//mearray=xmlHttp.responseText.split("[]");

					//alert(mearray);
			/*for (i=0;i<mearray.length-1;i++)
			{					
				if(mearray[i]!="")
				{
					valcat=mearray[i].split("{}");
					document.getElementById("awgali").innerHTML= valcat[0];	
					document.getElementById("awgaln").innerHTML= valcat[1];
				    document.getElementById("awgalc").innerHTML= valcat[2];
					document.getElementById("awgalp").innerHTML= valcat[3];		
					var g=('<img src="thumb_gallery/'+valcat[4]+'">');
					document.getElementById("awgali").innerHTML=g;
						}	
			}*/
			}
			}
			xmlHttp.open("GET",url,true)
			xmlHttp.send(null)	 
}		 



function valid_forget()







{	















var email=document.getElementById('reg-emailid').value;		







	alert(email);







			xmlHttp=GetXmlHttpObject()















			if (xmlHttp==null)















			{















			alert ("Browser does not support HTTP Request")















			return















			} 















			var url="chk_user.php?email="+email;		















			window.location=url;















			xmlHttp.onreadystatechange=function()















			{















				if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")















				{ 















					mearray=xmlHttp.responseText;















				element = document.getElementById("avbl");















				  element.innerHTML = mearray;















				}















			}































			xmlHttp.open("GET",url,true)















			xmlHttp.send(null)	







				







		







//return true;







}








