mmucklo / email-parse

Email\Parse is a multiple (and single) email address parser for php that is reasonably RFC822 / RFC2822 compliant.
MIT License
46 stars 15 forks source link

Internationalization: support accented names without escaping #16

Closed ArthurHoaro closed 3 years ago

ArthurHoaro commented 5 years ago

This PR allows to parse emails with accented names just as it already does with name without accents (without quotes).

For example, Testing Name <tname@asdf.ghjkl.com> becomes

With this change, the following failing use case Étienne Cloître <e.cloitre@domain.tld> will now be parsed with:

I also forced the PHP version in composer because it was failing with PHP 7.2 installed.

mmucklo commented 5 years ago

@ArthurHoaro

Okay, I've done some changes to tidy up things and make the minimum version to 7.1

Can you merge in my changes to your PR?

ArthurHoaro commented 3 years ago

Hey! Sorry it took me 2 years to update this PR. :grimacing:

But I think it's still valid, so I did while going through my open PRs. I also updated the implementation to avoid applying the regex twice.