Please help me make regular expression for positive decimal number with 0, 1 or 2 decimal places. It must allow comma and dot. For example it must allow:
0,0
/^\d+([.,]\d{1,2})?$/
this will properly disallow these "unformatted" numbers .01, 3., etc.
.01
3.
if we have zero decimal place digits we probably as well don't want the decimal separator.