On 06/10/2022 14:44, Claude Pache wrote:
While it may be difficult to validate an email according to some
IETF’s RFC, the HTML standard has pragmatically adopted a pattern
(used to validate `<input type=email>` fields) that is both readable
and suitable for most practical purposes. See:
https://html.spec.whatwg.org/multipage/input.html#valid-e-mail-address
Well, it would be a more clearly documented source than the current
implementation, although the spec admits it's "wilfully" not following
e-mail standards. I'd be happy to see it committed, maybe for PHP 8.3.
I note that it doesn't support internationalized addresses in their
Unicode form, though, so it won't do for FILTER_FLAG_EMAIL_UNICODE.
Regards,
--
Rowan Tommins
[IMSoP]
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: https://www.php.net/unsub.php