Regular Expressions 101

Community Patterns

Community Library Entry

1

Regular Expression
PCRE (PHP <7.3)

/
^(\w+(?:[\.-]?\w+)*)@(\w+(?:[\.-]?\w+)*)(\.[a-zA-Z]{2,})+$
/
g

Description

This one allows to begin with a digit, however, sometimes e-mail should begin with an **English letter **

Submitted by anonymous - 8 years ago