I want to validate textfield for user to enter only number like..
It should start from ‘ARRN’ and upto 5 numeric fields.
So number can be.. ARRN1 OR ARRN12 OR ARRN123 BUT NOT ARRN123456 AS ONLY 5 NUMERIC ALLOWED.
Can I have regex for the same in javascript to validate?
I tried with regex [‘ARRN’@[5]] But not sure about regex syntax.
You can use the follwong code to check that pattern. It will check the pattern in
onblurevent of the input.Working Fiddle