Regular Expressions 101

Community Patterns

Sign before number

1

Regular Expression
PCRE (PHP <7.3)

/
^(?=.*?[+-])(?=.*?[0-9]).[0-9]+$
/
gm

Description

Loading markdown...
Submitted by Albion Li├ži - 8 years ago