Email validation in admin modules

edited November 2014 in Bug Reports
I've got a project with one of the new TLD's ending in .fitness. Adding a Fuel admin user with this email address results in a "Please enter in a valid email address." validation fail. I've extended CI's Form_Validation to allow for longer suffixes but the admin module controller must be using another validation. Maybe? is the admin validation handled by another library?

Comments

  • edited 8:42AM
    There is a valid_email function in the validator_helper file. The last part of the regex has:
    [a-z]{2,6}
    If you change it to something like [a-z]{2,10}, does it then work for you?
  • edited 8:42AM
    Or even better:
    return filter_var($email, FILTER_VALIDATE_EMAIL);
    It looks like that function needs to be updated.
  • edited November 2014
    Yup, that nailed it! Thanks.
  • edited 8:42AM
    That's been pushed to the develop branch.
Sign In or Register to comment.