Support

Home Forums Event Espresso Premium Validate registration text field with RegEx?

Validate registration text field with RegEx?

Posted: June 20, 2016 at 4:54 pm


phillipsdriving

June 20, 2016 at 4:54 pm

Is there a way for me to validate one my form text input fields with a regex formula? It’s already required, but I need more validation that just that for this text field.


Josh

  • Support Staff

June 21, 2016 at 12:06 pm

Yes, this is possible if you have a working knowledge of jQuery and PHP. Here’s an example that shows how to add some custom validation to an EE4 registration form via a custom WordPress plugin.

https://gist.github.com/joshfeck/86a93df2cddfa7efba7427e66ab0b22b

You can your code that’s based on the above to a functions plugin or into your WordPress theme’s functions.php file.

The support post ‘Validate registration text field with RegEx?’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso