Hello,
I'm using last version of Gravity Forms (1.4.3.1) and it was very easy to set up a complex and lengthy form. The purpose of the form is to create a custom post type. This part is working thanks to hints I found on this forum. I'm trying now to set up checkboxes that will populate custom taxonomies when values are checked.
More details here:
- List A of checkboxes (id=24) for custom taxonomy 'access'
- List B of checkboxes (id=25) for custom taxonomy 'services'
Here is my PHP code:
This does not work as my vars 'choices_access' and 'choices_services' are empty before calling 'wp_set_object_terms'.
I've tried var_dump($choice) for debugging purpose in "foreach" loop, but even if I check a checkbox in the form, "IsSelected" property is set to "false" after submission.
- Am I using a wrong hook to populate my taxonomies? I've tried 'gform_pre_submission' hook, without any success.
- Is there a way to know if a checkbox was checked before hitting submission button?
Anyone can help?
Thanks!
Vincent