I am using the nifty parsley js As you can see in the documentation
there is only data-parsley-type="alphanum"
which allows numbers and letters. I am trying to create fields that ONLY allow letters.
Anyone know how to do this?
I am using the nifty parsley js As you can see in the documentation
there is only data-parsley-type="alphanum"
which allows numbers and letters. I am trying to create fields that ONLY allow letters.
Anyone know how to do this?
Share Improve this question asked May 1, 2014 at 20:12 user2684452user2684452 7313 gold badges14 silver badges34 bronze badges2 Answers
Reset to default 19You could use a pattern:
data-parsley-pattern="^[a-zA-Z]+$"
You can use such input validator, in order to obtain an only letter field.
<input type="text" class="form-control" required data-parsley-pattern="^[a-zA-Z ]+$" placeholder="Type something" />