Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Turn off email validation


DillyDog

Recommended Posts

Posted

Hi All

 

For some unexplained reason, new customers are not able to register if they have hotmail or gmail email address. As far as I know, this hasn't been a problem before and has just been brought to my attention by a frustrated customer.

Is there a way to turn this validation off, or edit the TLDs that the validation function uses?

 

The site in question is:

www.lostshop.co.uk

 

Any help is appreciated.

Posted

It should work, at least with hotmail.

 

Check in Admin-->Configuration-->Email Options. Set Verify email through DNS to false.

Grab a copy of osc from here and compare your catalog/includes/functions/validations.php against a clean one. That file has the tep_validate_email.

Posted

OK, tried all that, replaced 'validations.php' in both catalog/includes/functions/ and catalog/admin/includes/functions/ but it made no difference at all.

 

Any other suggestions?

Posted

OK, tried all that, replaced 'validations.php' in both catalog/includes/functions/ and catalog/admin/includes/functions/ but it made no difference at all.

 

Any other suggestions?

In create_account.php look for this piece of code.

   if (strlen($email_address) < ENTRY_EMAIL_ADDRESS_MIN_LENGTH) {
     $error = true;

     $messageStack->add('create_account', ENTRY_EMAIL_ADDRESS_ERROR);
   } elseif (tep_validate_email($email_address) == false) {
     $error = true;

     $messageStack->add('create_account', ENTRY_EMAIL_ADDRESS_CHECK_ERROR);
   } else {
     $check_email_query = tep_db_query("select count(*) as total from " . TABLE_CUSTOMERS . " where customers_email_address = '" . tep_db_input($email_address) . "'");
     $check_email = tep_db_fetch_array($check_email_query);
     if ($check_email['total'] > 0) {
       $error = true;

       $messageStack->add('create_account', ENTRY_EMAIL_ADDRESS_ERROR_EXISTS);
     }
   }

In paticular this part

   } elseif (tep_validate_email($email_address) == false) {
     $error = true;

     $messageStack->add('create_account', ENTRY_EMAIL_ADDRESS_CHECK_ERROR);

If yours is like that then you might be able to try changing this line

   } elseif (tep_validate_email($email_address) == false) {

to

   } elseif (tep_validate_email($email_address) === false) {

Note the extra " = " sign. Not sure if that will help you or if it is correct. If it still isn't working then I don't know what else to try.

  • 1 year later...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...