Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFC] - Improve email validation #7

Open
egulias opened this issue Apr 11, 2014 · 4 comments
Open

[RFC] - Improve email validation #7

egulias opened this issue Apr 11, 2014 · 4 comments
Assignees

Comments

@egulias
Copy link

egulias commented Apr 11, 2014

Hi!
The Email validator is curretnly ussing php built-in filter_var. As you may know it allows for false negatives on emails like name@localhost.
Would you consider integrating https://github.com/egulias/EmailValidator for the validation? It has been added as a (soft)dependency in Symfony (symfony/symfony#9140).
Swiftmailer is considering it to.
Thanks!

@gajus
Copy link
Owner

gajus commented Apr 11, 2014

"name@localhost" is a valid email address. What do you mean by false-positive?

On Apr 11, 2014, at 9:00, Eduardo Gulias Davis notifications@github.com wrote:

Hi!
The Email validator is curretnly ussing php built-in filter_var. As you may know it allows for false negatives on emails like name@localhost.
Would you consider integrating https://github.com/egulias/EmailValidator for the validation? It has been added as a (soft)dependency in Symfony (symfony/symfony#9140).
Swiftmailer is considering it to.
Thanks!


Reply to this email directly or view it on GitHub.

@egulias
Copy link
Author

egulias commented Apr 11, 2014

by false negative I mean that filter_var will say email@localhost is invalid.

@gajus
Copy link
Owner

gajus commented Apr 11, 2014

I hame misunderstood you.

var_dump(filter_var('email@localhost', FILTER_VALIDATE_EMAIL));

Yes, that's not right. I will consider https://github.com/egulias/EmailValidator as well as the alternatives.

@gajus gajus self-assigned this Apr 11, 2014
@egulias
Copy link
Author

egulias commented Apr 11, 2014

Great! Thanks. If you find an alternative, let me know so I can check it too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants