Conditional Custom Form Validation Question
-
My client has a from with some fields that are only required if a certain value has been selected. The basic logic is if the user has two options if they selects option one it presents them with another select with two options. From there they select an option and have to fill out two required text fields. But those are only required based on the selection they made. Otherwise if they’ve chosen option two the text fields for that option are required.
I’ve looked at the code here https://contactform7.com/2015/03/28/custom-validation and I’m not sure if I can access the value of the selects when validating the text fields? I admit my coding skills are rudimentary (and a bit rusty) so I hope this isn’t too ignorant a question.
Any advice on how or if this could be achieved (or if there’s a smarter way to do this) would be very much appreciated.
Thanks in advance for any help.
- The topic ‘Conditional Custom Form Validation Question’ is closed to new replies.