Regular Expressions 101

Community Patterns

1

loyal

PCRE2 (PHP >=7.3)
loyal
Submitted by anonymous - 4 days ago
1

named capture

PCRE2 (PHP >=7.3)
simple named capture
Submitted by Gene - 4 days ago
1

extract url

PCRE2 (PHP >=7.3)
extract url
Submitted by anonymous - 17 days ago

URL regexp

40

Regular Expression
PCRE (PHP <7.3)

/
((([A-Za-z]{3,9}:(?:\/\/)?)(?:[-;:&=\+\$,\w]+@)?[A-Za-z0-9.-]+|(?:www.|[-;:&=\+\$,\w]+@)[A-Za-z0-9.-]+)((?:\/[\+~%\/.\w-_]*)?\??(?:[-\+=&;%@.\w_]*)#?(?:[.\!\/\\w]*))?)
/
ig

Description

Loading markdown...
Submitted by Matthew O'Riordan - 11 years ago