Regular Expressions 101

Community Patterns

1

datime

PCRE2 (PHP >=7.3)
datetime
Submitted by anonymous - 3 days ago
1

Match paths

PCRE2 (PHP >=7.3)
Match paths
Submitted by os_niko - 10 days ago

Match any url in text or html (http, https)

3

Regular Expression
PCRE2 (PHP >=7.3)

/
(?:http[s]?:\/\/.)?(?:www\.)?[-a-zA-Z0-9@%._\+~#=]{2,256}\.[a-z]{2,6}\b(?:[-a-zA-Z0-9@:%_\+.~#?&\/\/=]*)
/
gm

Description

Loading markdown...
Submitted by Jérémy Munsch - 2 years ago