samedi 17 octobre 2015

Text Field Validation With REGEX and Proper Error Message In Rails 4

At First, my question may seems as a duplicate one to you, but surely not, I will explain why, because all the stack overflow answer regarding name validation, text field validation explain about validation with a message only...!

My requirement is different that in my validation check I need to allow only characters(Using REGEX), and if anything else entered, error must be displayed. How can I achieve it ?

Please dont report it as duplicate as I will get blocked with next false reporting..... if you stil find it as a duplicate question please comment me the link that I have not yet seen in comment box, then I will delete my question, anyhow I dont need to get locked in using stack overflow... :(

Aucun commentaire:

Enregistrer un commentaire