Giter VIP home page Giter VIP logo

Comments (4)

derickr avatar derickr commented on July 19, 2024

Hi,

I'll have a look. I don't think there is anything wrong with this line, so moving to filter_var() with FILTER_VALIDATE_EMAIL was probably the wrong choice.

Do you have a set of emails that are now broken, and also your original broken one from the issue in civic that you linked to? We can then add these as test cases.

cheers,
Derick

from mail.

derickr avatar derickr commented on July 19, 2024

I had a little dive into RFCs, and filter_var() does do this correctly. Local parts are limited to 64 octets, and your example "email address" has more.

I do think it is important that we validate this, and that we don't just return null when it isn't valid. I also believe that when parsing we should be more lenient in what we accept.

My suggestion would be to use the regex from PHP's filter_var() and extend the length limits. The PR at #91 does this, and extends it from 64 to 124.

from mail.

derickr avatar derickr commented on July 19, 2024

I've merged this, and also released 1.9.6.

from mail.

eileenmcnaughton avatar eileenmcnaughton commented on July 19, 2024

Thanks for being so helpful @derickr

from mail.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.