Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

11
  • 12
    The regex that can validate that an IDNA is correctly formatted does not fit in stackexchange. (the rules on canonicalisation ate really tortuous and particularly ill-suited to regex processing) Commented Aug 29, 2017 at 23:51
  • 15
    Why you should not do this: Can it cause harm to validate email addresses with a regex? Commented Jan 9, 2018 at 14:30
  • The regexes may be variable as in some cases, an email con can contain a space, and in other times, it cannot contain any spaces. Commented Jul 23, 2018 at 4:21
  • You can check Symfonys regex for loose and strict check: github.com/symfony/symfony/blob/5.x/src/Symfony/Component/… Commented May 16, 2021 at 16:15
  • Using just regex can harm server security but if it is just as an input pattern, i suggest use this: stackoverflow.com/questions/5601647/… Commented Jun 7, 2021 at 21:42