Whats wrong with this regular expression?
^[a-zA-Z,\d,\&,\#,\-,\(,\']{3,15}$
Valid input is alphanumeric, space, #, &, ', , - with max and minimum length of 3 and 15 respectively.
when I enter the following valid input, it fails:
MT90#&' ABCD
You missed space
\s, and no need to use,in char set.This will be ok:
Update:
\swill match on all whitespace (including tabs and line breaks as well as spaces), if you want just space, change to :