Hi all,
I have this bit of code that checks if the user has entered a 5 digit number in a box.
I want to change it so that it only checks the user has entered 5 characters (digits or alphabet). I honestly dont know my way around jQuery or PHP at all!
I have this bit of code that checks if the user has entered a 5 digit number in a box.
Code:
jQuery.validator.addMethod("IDValidation", function (value, element) {
return /^\d{5}$/.test(value);
}, "Incorrect Code");
I want to change it so that it only checks the user has entered 5 characters (digits or alphabet). I honestly dont know my way around jQuery or PHP at all!