Skip Navigation

[Resolved] Toolset Forms add to Post Group

This support ticket is created 4 years, 1 month 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.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

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 1 reply, has 2 voices.

Last updated by Luo Yang 4 years, 1 month ago.

Assisted by: Luo Yang.

Author
Posts
#1808665

I was wondering if there is a way to use Toolset Forms to allow users to add a post to a Post Group.

Essentially, I would like them to create a post and add it to a Post Group from a list of already created Post Groups (which I will have created) without giving them access to the backend. I know how to use Toolset forms to allow them to create a new post but not sure if adding to a post group is also possible

Thanks!

#1810731

Hello,

There isn't such kind of built-in feature within Toolset Forms plugin, you might consider custom codes, for example, :
1) In admin side, create a new post, and setup specific Post Group, save the post
Check your database with mysql Tool, in table wp_postmeta, search with:
post_id = your new post ID
meta_key = _wpcf_access_group
You will get one item, the meta_value is the specific Post Group's ID, something like this:
wpcf-custom-group-87e28517d9ffb821318d8c1e84684024

2) When your user submit the Toolset post form, use action hook cred_save_data to trigger a PHP function:
https://toolset.com/documentation/programmer-reference/cred-api/#cred_save_data
In this PHP function, setup the custom field "_wpcf_access_group" value to the specific Post Group's ID of step 1)
https://developer.wordpress.org/reference/functions/update_post_meta/