function showPrice()
 {
   var custtype = document.registrationfrm.vcustomer_type.options[document.registrationfrm.vcustomer_type.selectedIndex].value;
   for(var i = 0; i < document.registrationfrm.reg_option.length; i++) {
      if(document.registrationfrm.reg_option[i].checked == true)
         var option   = document.registrationfrm.reg_option[i].value;
   } 
   ajx.set_mode('price') ;
   ajx.add_element('div_price') ;
   ajx.ajaxRead('scripts/ajx.php?mode=price&custtype='+custtype + '&option=' + option);
}
function forgot_mail(formName)
{
		flg = validateBlank(formName,'vemail','Please Enter the Email Address')
		if (!flg) return false
		
		flg = validateEmail(formName,'vemail','Please Enter A Valid Email')
		if(!flg) return false
}

function changepassform(formName)
{
		flg = validateBlank(formName,'old_pass','Please Enter the Old Password')
		if (!flg) return false
		
		flg = validateBlank(formName,'new_pass','Please Enter the New Password')
		if (!flg) return false
		
		flg = validateBlank(formName,'confirm_pass','Please Enter the Confirm Password')
		if (!flg) return false
		
		flg = validateconfirmpass(formName,'new_pass','confirm_pass','Please Check Confirm Password')
		if (!flg) return false
}
function checkaddform(formName)
{
		flg = validateBlank(formName,'vemail','Please Enter the Email Address')
		if (!flg) return false
		
		flg = validateEmail(formName,'vemail','Please Enter A Valid Email')
		if(!flg) return false
		
		flg = validateBlank(formName,'vpassword','Please Enter the Password')
		if (!flg) return false
}
function check_registrationform(formName)
{
		flg = validateBlank(formName,'vemail','Please Enter the Email Address')
	    if (!flg) return false
		
		flg = validateEmail(formName,'vemail','Please Enter A Valid Email')
	    if(!flg) return false
		
		flg = validateBlank(formName,'vpassword','Please Enter the Password')
		if (!flg) return false
		
		flg = validateBlank(formName,'confirm_password','Please Enter the Confirm Password')
		if (!flg) return false
		
		flg = validateconfirmpass(formName,'vpassword','confirm_password','Please Check Confirm Password')
		if (!flg) return false
		
		flg = validateBlank(formName,'vfirstname','Please Enter the First Name')
		if (!flg) return false
		
		flg = validateBlank(formName,'vlastname','Please Enter the Last Name')
		if (!flg) return false
		
		flg = validateBlank(formName,'dob','Please Select Date of birth')
		if (!flg) return false
		
		flg = validateBlank(formName,'vaddress1','Please Enter the Address')
		if (!flg) return false
		
		flg = validateBlank(formName,'vcity','Please Enter the City')
		if (!flg) return false
				
			
		/*flg = validateBlank(formName,'vstate','Please Select the State')
		if (!flg) return false*/
		
		flg = validateBlank(formName,'vphone','Please Enter the Phone')
		if (!flg) return false
		
		flg = validateBlank(formName,'vzip','Please Enter the Zip')
		if (!flg) return false
		
		flg = validateBlank(formName,'number','please enter card number')
		if (!flg) return false
		
		flg = validateBlank(formName,'vsecurity','please enter security number')
		if (!flg) return false
		
		flg = validateBlank(formName,'exp_month','please select exp_month')
		if (!flg) return false
		
		flg = validateBlank(formName,'exp_year','please select exp_year')
		if (!flg) return false
		
		flg = validateCCNum(document.registrationfrm.card.value,document.registrationfrm.number.value)
		if (!flg) 
		{
		    alert("Please enter proper card number");
			document.registrationfrm.number.focus();
			return false;
		}
		
		var expdate=document.registrationfrm.exp_month.value + "/"+ document.registrationfrm.exp_year.value;
		flg = validCCForm(document.registrationfrm.card,document.registrationfrm.number,expdate)
		if (!flg) 
		{
			document.registrationfrm.exp_month.focus();
			return false;
		}
		
		flg = validateNumber("registrationfrm","vsecurity","Please enter proper card identification number")
		if (!flg) return false
		
		if(document.registrationfrm.vsecurity.value.length < 3){
			alert("Please Enter Proper Card Indentification Number");
			document.registrationfrm.vsecurity.focus();
			return false;
		}
		if (document.registrationfrm.terms.checked == false)
		{
			alert ('You must Agree to Terms and Services of Link2 Global Luxury!');
			return false;
		}
}

function update_account(formName)
{
		flg = validateBlank(formName,'vemail','Please Enter the Email Address')
	    if (!flg) return false
		
		flg = validateEmail(formName,'vemail','Please Enter A Valid Email')
	    if(!flg) return false
		
		flg = validateBlank(formName,'vfirstname','Please Enter the First Name')
		if (!flg) return false
		
		flg = validateBlank(formName,'vlastname','Please Enter the Last Name')
		if (!flg) return false
		
		flg = validateBlank(formName,'vaddress','Please Enter the Address')
		if (!flg) return false
		
		flg = validateBlank(formName,'vcity','Please Enter the City')
		if (!flg) return false
				
			
		flg = validateBlank(formName,'vstate','Please Select the State')
		if (!flg) return false
		
		flg = validateBlank(formName,'vzip','Please Enter the Zip')
		if (!flg) return false
		
		flg = validateBlank(formName,'vphone','Please Enter the Phone')
		if (!flg) return false
}

function checkContactForm(formName)
{
		flg = validateBlank(formName,'vfirstname','Please Enter the First Name')
		if (!flg) return false
		
		flg = validateBlank(formName,'vlastname','Please Enter the Last Name')
		if (!flg) return false
		
		flg = validateBlank(formName,'vaddress','Please Enter the Address')
		if (!flg) return false
		
		flg = validateBlank(formName,'vcity','Please Enter the City')
		if (!flg) return false
		
		flg = validateBlank(formName,'vemail','Please Enter the Email Address')
	    if (!flg) return false
		
		flg = validateEmail(formName,'vemail','Please Enter A Valid Email')
	    if(!flg) return false
	
		flg = validateBlank(formName,'vphone','Please Enter the Phone')
		if (!flg) return false
		
		flg = validateBlank(formName,'vcomment','Please Enter your comments')
		if (!flg) return false
}



function checkadddoctor()
{
     theForm  = document.frmMain;
     if(theForm.txtName.value == "")
     {
        alert("Please enter Physician Name");
	    theForm.txtName.focus();
	    return false;
     }
	 if(theForm.txtPAAddress.value == "")
     {
        alert("Please enter Address");
	    theForm.txtPAAddress.focus();
	    return false;
     }
	 if(theForm.txtPACity.value == "")
     {
        alert("Please enter City");
	    theForm.txtPACity.focus();
	    return false;
     }
	  if(theForm.txtPAZip.value == "")
     {
        alert("Please enter Zip");
	    theForm.txtPAZip.focus();
	    return false;
     }
	  if(theForm.txtPAPhone.value == "")
     {
        alert("Please enter Phone");
	    theForm.txtPAPhone.focus();
	    return false;
     }
	 
	  if(theForm.txtSName.value == "")
     {
        alert("Please enter Medical school name");
	    theForm.txtSName.focus();
	    return false;
     }
	  if(theForm.txtSCity.value == "")
     {
        alert("Please enter Medical school city");
	    theForm.txtSCity.focus();
	    return false;
     }
	 if(theForm.txtRSName.value == "")
     {
        alert("Please enter Residentail place name");
	    theForm.txtRSName.focus();
	    return false;
     }
    if(theForm.txtRSCity.value == "")
     {
        alert("Please enter Residentail place city");
	    theForm.txtRSCity.focus();
	    return false;
     }	
}

function checkaddhospital()
{
     theForm  = document.frmMain;
     if(theForm.vname.value == "")
     {
        alert("Please enter Hospital Name");
	    theForm.vname.focus();
	    return false;
     }
	 if(theForm.vaddress.value == "")
     {
        alert("Please enter Address");
	    theForm.vaddress.focus();
	    return false;
     }
	 if(theForm.vcity.value == "")
     {
        alert("Please enter City");
	    theForm.vcity.focus();
	    return false;
     }
	  if(theForm.vzip.value == "")
     {
        alert("Please enter Zip");
	    theForm.vzip.focus();
	    return false;
     }
	  if(theForm.vphone.value == "")
     {
        alert("Please enter Phone");
	    theForm.vphone.focus();
	    return false;
     }
}

function check_adduser(formName)
{
		flg = validateBlank(formName,'vemail','Please Enter the Email Address')
	    if (!flg) return false
		
		flg = validateEmail(formName,'vemail','Please Enter A Valid Email')
	    if(!flg) return false
		
		flg = validateBlank(formName,'vpassword','Please Enter the Password')
		if (!flg) return false
		
		flg = validateBlank(formName,'vfirstname','Please Enter the First Name')
		if (!flg) return false
		
		flg = validateBlank(formName,'vlastname','Please Enter the Last Name')
		if (!flg) return false
		
		flg = validateBlank(formName,'vaddress','Please Enter the Address')
		if (!flg) return false
		
		flg = validateBlank(formName,'vcity','Please Enter the City')
		if (!flg) return false
				
			
		flg = validateBlank(formName,'vstate','Please Select the State')
		if (!flg) return false
		
		flg = validateBlank(formName,'vzip','Please Enter the Zip')
		if (!flg) return false
		
		flg = validateBlank(formName,'vphone','Please Enter the Phone')
		if (!flg) return false
		
		flg = validateBlank(formName,'vcard_num','please enter card number')
		if (!flg) return false
		
		flg = validateBlank(formName,'vsecurity_code','please enter security number')
		if (!flg) return false
		
		flg = validateBlank(formName,'exp_month','please select exp_month')
		if (!flg) return false
		
		flg = validateBlank(formName,'exp_year','please select exp_year')
		if (!flg) return false
		
		flg = validateCCNum(document.registrationfrm.vcard_type.value,document.registrationfrm.vcard_num.value)
		if (!flg) 
		{
		    alert("Please enter proper card number");
			document.registrationfrm.vcard_num.focus();
			return false;
		}
		
		var expdate=document.registrationfrm.exp_month.value + "/"+ document.registrationfrm.exp_year.value;
		flg = validCCForm(document.registrationfrm.vcard_type,document.registrationfrm.vcard_num,expdate)
		if (!flg) 
		{
			document.registrationfrm.exp_month.focus();
			return false;
		}
		
		flg = validateNumber("registrationfrm","vsecurity_code","Please enter proper card identification number")
		if (!flg) return false
		
		if(document.registrationfrm.vsecurity_code.value.length < 3){
			alert("Please Enter Proper Card Indentification Number");
			document.registrationfrm.vsecurity_code.focus();
			return false;
		}
}

