I\'d like to use jQuery\'s validation plugin to validate a field that only accepts alphabetical characters, but there doesn\'t seem to be a defined rule for it. I\'ve search
Just a small addition to Nick's answer (which works great !) :
If you want to allow spaces in between letters, for example , you may restrict to enter only letters in full name, but it should allow space as well - just list the space as below with a comma. And in the same way if you need to allow any other specific character:
jQuery.validator.addMethod("lettersonly", function(value, element)
{
return this.optional(element) || /^[a-z," "]+$/i.test(value);
}, "Letters and spaces only please");