in reply to Re^2: Regular Expression Currency Check
in thread Regular Expression Currency Check

I think I got it, I just would like to add the last check, if value is more them 99999.99 to the reg. exp. as well, and here is the code so far:

if ( ($payment=~/^\s*\$?(\d{1,3},(\d{3},)*\d{3}|\d+)(\.\d +{2})\s*$/) || ($payment > 99999.99) ) { print "^*$1-$2-$3-match*$payment*match*^<br>"; }else{print "No match";}