Regex validation with decimal -


working on regex validation, validate xx,xx. mine regex can write 2,233 , still go through:

'regex:/[\d]{1,2},[\d]{2}/', 

maybe should add start , end limits follows:

'regex:/^\d{1,3},\d{2}$/' 

demo: http://regex101.com/r/qw1cv2


Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -