I use the plugin freeform and now i need a checkbox/lightswitch/selectbox where i can select a specific behaviour (custom variable/attribute)

So i simply want to add a checkbox above "Collect IP Addresses" (or any other place) in the form settings. I think i need a plugin which extends the freeform-plugin. But i can not find a hook/example how to add fields/variables/attributes in the adminpanel, which can be checked by the admin/user and are available in the further process.

To explain it more in detail: I use a custom plugin to extend the behaviour after submit - so a custom action happens. If the checkbox is checked, a second action should be triggered. I do not want to define the handles of specific forms, because the adminuser should be able to create a new form and enable my switch.

I tried to create i lightswitch field on the same page, where i insert the form. But because of using "freeform.form(xxx).render" i am not able to transfer my variable into the "EVENT_AFTER_SUBMIT"

Hope you understand my thoughts and someone has a good idea on how to solve this. Maybe it is even impossible, even this would help me ;)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.