Regular Expressions 101

Community Patterns

regex101.com id grabber

483

Regular Expression
PCRE (PHP <7.3)

/
^http(?:s?):\/{2}regex101\.com\/r\/([a-zA-Z0-9]{1,6})?$
/
gm

Description

grabs the ID for the regex101.com permalink to code

Submitted by chris mccoy - 10 years ago (Last modified 8 months ago)