4 ms·
> If you were to ask me for a regex, I'd say /.+@.+/ How about "one@two@three@four@example.com"?
by s_kilk 11y ago
> If you were to ask me for a regex, I'd say /.+@.+/
How about "one@two@three@four@example.com"?
- ketralnis 11y agoYes there are loads of invalid email addresses it allows. It's not supposed to be perfect.
- Freak_NL 11y agoYeah, the point of checking for the @ is chiefly to prevent inexperienced users (e.g., elderly) from entering the wrong type of data. For example, enter a line from their postal address instead of their email address.
- mcv 11y agoAny validation is also going to allow "someonewhodoesntexist@nonexistentdomain.com", unless you send an email to it.