Regular Expressions 101

Community Library Entry

1

Regular Expression
ECMAScript (JavaScript)

/
^[0-9]{1,3}((\,[0-9]{3})*)\.[0-9]{2}$
/
gm

Description

Valid: 0.00 123.12 123,123,123.12 123,123,123,123.00

Invalid: 12,1234,123.12 1234,123.12

Submitted by Benji W J YANG - 7 years ago