Regular Expressions 101

Library entries

RegEx to add any valid US phone number inputs

Vote

1

Regular Expression
pcre2

/
^(1?)(?:((\s?\(\d{3}\)\s?|\s?\d{3}\s?)\-?\d{3}\s?\-?\d{4}$))
/
gm

Description

Loading markdown...
Submitted by @abhi00o7 - 4 months ago