Regular Expressions 101

Community Patterns

Community Library Entry

2

Regular Expression
PCRE (PHP <7.3)

/
([\S]+@[\w]+(?:\.[\w]+)+)
/
gi

Description

Picks out valid email addresses from string.

Submitted by Rob Lester - 9 years ago