Reputation: 193
can you please help me to write a regular expression where it allows comma separated Numeric values. Below is the Expression that i have tried.
Expression : /^[0-9,]+$/
Test String : 123,111
--> Shows as Match --> Correct
Test String : 123,111,
-- > Shows as Match --> Incorrect --> if comma is specified it should follow with number
Upvotes: 1
Views: 541