Title: Form fileds php validation
Last modified: March 22, 2023

---

# Form fileds php validation

 *  Resolved [ziskar364](https://wordpress.org/support/users/ziskar364/)
 * (@ziskar364)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/form-fileds-php-validation/)
 * Hi I would like to ask if we can validate the form fields not only in the frontend
   but also in the php.

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Support [Laura – WPMU DEV Support](https://wordpress.org/support/users/wpmudev-support8/)
 * (@wpmudev-support8)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/form-fileds-php-validation/#post-16584307)
 * Hi [@ziskar364](https://wordpress.org/support/users/ziskar364/)
 * I hope you’re well today!
 * Form can be set to use server-side validation (via the “Validation” setting in“
   Behavior” section of form configuration) but this only changes the “method” and
   still doesn’t let you validate in custom way.
 * Do do some custom validation (as I suppose that’s what you mean – custom validation
   of data via your own PHP script) you would need to hook your custom PHP code 
   to the Forminator’s “_submit_errors” filter hook.
 * Here is an example of how to do this:
 * [https://gist.github.com/adczk/728fff7d4061eff16bcd60593eba337d](https://gist.github.com/adczk/728fff7d4061eff16bcd60593eba337d)
 * This particular example is is about preventing submission of the same data multiple
   times but the code can be modified to do pretty much any kind of validation. 
   Take a look into it and if you have any additional questions, let us know, please.
 * Best regards,
    Adam
 *  Thread Starter [ziskar364](https://wordpress.org/support/users/ziskar364/)
 * (@ziskar364)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/form-fileds-php-validation/#post-16584318)
 * Dear Adam, thank you very much for your quick response and useful information.
   
   I will try and let you know if any further assistance is necessary.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Form fileds php validation’ is closed to new replies.

 * ![](https://ps.w.org/forminator/assets/icon-256x256.gif?rev=3443182)
 * [Forminator Forms – Contact Form, Payment Form & Custom Form Builder](https://wordpress.org/plugins/forminator/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/forminator/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/forminator/)
 * [Active Topics](https://wordpress.org/support/plugin/forminator/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/forminator/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/forminator/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [ziskar364](https://wordpress.org/support/users/ziskar364/)
 * Last activity: [3 years, 2 months ago](https://wordpress.org/support/topic/form-fileds-php-validation/#post-16584318)
 * Status: resolved