The Community forums are being phased out in favor of a new Slack group.
Add your email address below to get an invitation to join the community slack group

Slack Signup
Newsletter Optin
Help Desk

Custom Addon Field Data (radio buttons) state not being saved

Labels

This Discussion is public

Notifications

I create an addon for formidable, when submitting the form (if there is an error) it returns back to the form.   All normal formidable form data is saved, but my custom package fields are empty.  So the data is not persisting.   What would be the best way to resolve this issue?

I'm in the process of finishing up an add-on plugin for a client that includes one custom field and also adds an option to existing fields.

Trying to explain how to solve your problem requires understanding how you've coded your add-on. For example, how you're initializing the field, setting its defaults, displaying it, and saving its results.

What I've found in the past is that it is easy to reinitialize a field to its default value because the default value function is not taking into account whether the value already exists in the $field or $field['field_options'] arrays.

It's also possible that you missed a hook in your hooks controller class.

This is just a guess without examining the source, but I hope it helps point you in the right direction anyway.

Discussion closed.