Skip Navigation

[Resolved] Add fields and Add generic fields options in Toolset form

This support ticket is created 6 years, 3 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 3 replies, has 2 voices.

Last updated by Luo Yang 6 years, 3 months ago.

Assisted by: Luo Yang.

Author
Posts
#1150372

I have questions about the Custom Post Type - Custom Fields that I create/add, and the Auto-generate form content, Add fields, and Add generic fields options on the Form creation tool.

I believe that the Auto-generate button will insert the custom fields group created in the custom post type. What will happen if I create more form fields using the Add fields and Add generic fields options? In one article, I read that content entered in the generic fields will not be saved to the database. Is this correct? What about the Add fields option? What will happen to data entered in those fields. And last, is it safe to conclude that data entered in the custom field group from the custom post type will be entered into the database?

Thank you

#1150377

Hi,

Yes, you are right, generic fields will not be saved to the database by default, but you can manually add parameter "persist : 1"into generic field shortcode, for example:
There is a "my-field" single line created with Types plugin

[cred_generic_field field="wpcf-my-field" type="textfield" class=""]
{
"required":0,
"validate_format":0,
"default":"",
"persist":1
}
[/cred_generic_field]

It can save the user's input into database too.

But the best option is using "Add fields" button, it works with custom fields/taxonomies created with Types plugin, it will setup [cred_field] shortcode automatically, see our document:
https://toolset.com/documentation/user-guides/cred-shortcodes/#cred_field
Render a form field (using fields defined in Toolset Types plugin and / or Taxonomies).

#1150385

This is great - Thank you for sharing and creating a new thread.

#1150453

OK, please update here if you need more assistance for it.