Regular Expressions 101

Community Patterns

Community Library Entry

0

Regular Expression
PCRE2 (PHP >=7.3)

/
^(?P<UserAction>\w+\s)?(?P<email>(?:[\w\.\-]+)@(?:[\w\-]+)(?:(?:\.(?:\w){2,3})+))\s(?:from|requested|to|joined)?(?:user\stype\sto)?\s(?P<userType>(Basic|Full|Core))?.*
/
gm

Description

Pulls out action verbs, emails and usertypes

Submitted by anonymous - 2 years ago