function show_turnover_INR()
{
		document.USER_REG.turnover.options[0].text = "Below Rs. 100 Crore";
		document.USER_REG.turnover.options[1].text = "Rs. 100 Crore - 500 Crore";
		document.USER_REG.turnover.options[2].text = "Rs. 500 Crore - 1000 Crore";
		document.USER_REG.turnover.options[3].text = "Rs. 1000 Crore - 5000 Crore";
		document.USER_REG.turnover.options[4].text = "Rs. 5000 Crore - 10,000 Crore";
		document.USER_REG.turnover.options[5].text = "Above 10,000 Crore";
return true;
}


function show_turnover_USD()
{
		document.USER_REG.turnover.options[0].text = "Below $1 Million";
		document.USER_REG.turnover.options[1].text = "$1 Million - $5 Million";
		document.USER_REG.turnover.options[2].text = "$5 Million - $10 Million";
		document.USER_REG.turnover.options[3].text = "$10 Million - $50 Million";
		document.USER_REG.turnover.options[4].text = "$50 Million - $100 Million";
		document.USER_REG.turnover.options[5].text = "$100 Million - $1 Billion";
return true;
}


function get_c_code() {
	 document.USER_REG.c_code_fax.value = document.USER_REG.c_code.value;
}


function get_area_code() {
	 document.USER_REG.area_code_fax.value = document.USER_REG.area_code.value;
}


function checkuserform()
{
	if (document.USER_REG.username.value.length == 0){
	alert("Please first fill your User Id."); 
	document.USER_REG.username.focus();
	return false;
	}
	if (document.USER_REG.password.value.length == 0){
	alert("Please first fill your password."); 
	document.USER_REG.password.focus();
	return false;
	}
	if (document.USER_REG.password_conf.value.length == 0){
	alert("Please first fill your password again for confirmation."); 
	document.USER_REG.password_conf.focus();
	return false;
	}	
	if (document.USER_REG.password.value != document.USER_REG.password_conf.value){
	alert("Your password should be same at both places."); 
	document.USER_REG.password_conf.focus();
	return false;
	}
	if (document.USER_REG.realname.value.length == 0){
	alert("Please first fill your name."); 
	document.USER_REG.realname.focus();
	return false;
	}	
	if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,4})+$/.test(document.USER_REG.email.value)))
	{
		alert("Invalid Email ID. Kindly enter the correct ID.");
		document.USER_REG.email.focus();
		return (false);
	}
	if (document.USER_REG.designation.value.length == 0){
	alert("Please first fill your designation."); 
	document.USER_REG.designation.focus();
	return false;
	}
	if (document.USER_REG.comp_name.value.length == 0){
	alert("Please first fill your company name."); 
	document.USER_REG.comp_name.focus();
	return false;
	}
	if (document.USER_REG.total_emp.value.length == 0){
	alert("Please first fill your company's total employee no."); 
	document.USER_REG.total_emp.focus();
	return false;
	}
	if (isNaN(document.USER_REG.total_emp.value)){
	alert("Please first fill valid no of employees."); 
	document.USER_REG.total_emp.focus();
	return false;
	}
	if (document.USER_REG.comp_description.value.length == 0){
	alert("Please first fill your company description."); 
	document.USER_REG.comp_description.focus();
	return false;
	}
	if (document.USER_REG.address1.value.length == 0){
	alert("Please first fill your address."); 
	document.USER_REG.address1.focus();
	return false;
	}
	if (document.USER_REG.city.value.length == 0){
	alert("Please first fill city."); 
	document.USER_REG.city.focus();
	return false;
	}
	
	var countryidx = document.USER_REG.country.selectedIndex;
	if (document.USER_REG.country.options[countryidx].value == ""){
		alert("Please first select any country."); 
		document.USER_REG.country.focus();
		return false;
	}

	var countryid = document.USER_REG.country.options[countryidx].value;
	if (countryid == "IN") {
		var stateidx = document.USER_REG.state.selectedIndex;
		if (document.USER_REG.state.options[stateidx].value == ""){
			alert("Please first select any state or union territory of India."); 
			document.USER_REG.state.focus();
			return false;
		}
	}

	if (document.USER_REG.zip.value.length == 0){
	alert("Please first fill city zip code."); 
	document.USER_REG.zip.focus();
	return false;
	}
    if (document.USER_REG.c_code.value.length == 0){
	alert("Please first fill your country code."); 
	document.USER_REG.c_code.focus();
	return false;
	}
	if (document.USER_REG.area_code.value.length == 0){
	alert("Please first fill your area code."); 
	document.USER_REG.area_code.focus();
	return false;
	}
	if (document.USER_REG.phone_office.value.length == 0){
	alert("Please first fill your company phone no."); 
	document.USER_REG.phone_office.focus();
	return false;
	}
	else {
		return true;
	}	
} // end function


function state_change() 
{
var old_state = document.USER_REG.state.length - 1;
for(j=old_state;j>=0;j--) {
	document.USER_REG.state.options[j] = null;			
}
if(document.USER_REG.country.options[document.USER_REG.country.selectedIndex].value == "IN") {
var opt0 = new Option("- Select State -","","","TRUE");
var opt1 = new Option("Madhya Pradesh",20);
var opt2 = new Option("Maharashtra",21);
var opt3 = new Option("Manipur",22);
var opt4 = new Option("Meghalaya",23);
var opt5 = new Option("Mizoram",24);
var opt6 = new Option("Nagaland",25);
var opt7 = new Option("Orissa",26);
var opt8 = new Option("Pondicherry",27);
var opt9 = new Option("Punjab",28);
var opt10 = new Option("Rajasthan",29);
var opt11 = new Option("Andaman And Nicobar",1);
var opt12 = new Option("Andhra Pradesh",2);
var opt13 = new Option("Arunachal Pradesh",3);
var opt14 = new Option("Delhi",10);
var opt15 = new Option("Assam",4);
var opt16 = new Option("Goa",11);
var opt17 = new Option("Bihar",5);
var opt18 = new Option("Gujarat",12);
var opt19 = new Option("Chandigarh",6);
var opt20 = new Option("Haryana",13);
var opt21 = new Option("Chattisgarh",7);
var opt22 = new Option("Himachal Pradesh",14);
var opt23 = new Option("Dadra And Nagar",8);
var opt24 = new Option("Sikkim",30);
var opt25 = new Option("Tamilnadu",31);
var opt26 = new Option("Daman And Diu",9);
var opt27 = new Option("Jammu And Kashmir",15);
var opt28 = new Option("Tripura",32);
var opt29 = new Option("Jharkhand",16);
var opt30 = new Option("Uttar Pradesh",33);
var opt31 = new Option("Karnataka",17);
var opt32 = new Option("Uttranchal",34);
var opt33 = new Option("Kerala",18);
var opt34 = new Option("Lakshadweep",19);
var opt35 = new Option("West Bengal",35);

 for(x=0;x<36;x++)	{
				eval("document.USER_REG.state.options[x] = opt"+x);
				}
 
			}
			else {
				if(document.USER_REG.country.options[document.USER_REG.country.selectedIndex].value != "IN") {
					var opt0 = new Option("- Not Required -","","","TRUE");
					eval("document.USER_REG.state.options[0] = opt0");
				}
				if(document.USER_REG.country.options[document.USER_REG.country.selectedIndex].value == "") {
					var opt0 = new Option("- Please First Select Country -","","","TRUE");
					eval("document.USER_REG.state.options[0] = opt0");
				}
			}
 return true; 
}