Support forumCategory: QuestionsCustom Validation
Cameron JP asked 7 months ago

I am looking for the best method to add some basic validation for one of my custom fields This is a unique reference that people need to input. I needs to follow the patterm 0NNNNN where N is any digit. (regex = /^0\d{5}$/).
I would like this validation to occur in a similar manner to how the email works where this is checked each time a key has been pressed or on focus out – that shows 2 errors, field is empty, or pattern invalid. Is there some form of callback that I can leverage to do this?
Alternatively, I was thinking of supplying that field as a GET param?
Any thoughts would be appreciated.

1 Answers
Nikola Loncar Staff answered 7 months ago

Hi, have you tried masked field? There you can set format that you need for your customers?

Best regards,