3 ms·
Validation errors are common, but warnings are not. I'd like to see more of "Patterns like [what you entered] are uncommon—are you sure?" instead of "Patterns
by mLuby 5y ago
Validation errors are common, but warnings are not.
I'd like to see more of "Patterns like [what you entered] are uncommon—are you sure?" instead of "Patterns like [what you entered] are not allowed—change it to proceed."
- richeyryan 5y agoI recently implemented this using the great Mailcheck library. So if someone types "gnail.com" or "gmail.con" it detects it and we can show "Did you mean gmail.com?". If someone ignores the suggestion, fair enough. If someone purposely wants to give us a junk email, fair enough. At least we're not frustrating them needlessly. https://github.com/mailcheck/mailcheck https://github.com/mailcheck/mailcheck
- zzo38computer 5y agoMostly, yes. However, some things should probably still be prohibited, such as: - An email address ending with ".invalid", unless invalid email addresses are supposed to be allowed (which in some cases is useful, but you can then disable sending email to such an address, using it only for identification). (I do use such an email address for identification on NNTP.) - Email addresses without at least one at sign. - Email addresses containing control characters (at least ASCII control characters). - If the domain name does not resolve or resolves to a loopback address or LAN address (except for some specialized cases where such a thing is desirable). The same is true for literal IP addresses; if it is a loopback or LAN address then it should be disallowed, but otherwise it can be allowed.