I am trying to: i need to limit the serving of a specific part of a product page only to selected groups; the groups have been created using the "Groups" plugin (see: hidden link - see attached screen #1): my aim is to serve only a part of the page to selected registered users.
i created a custom content area in the backend with the toolset plugin (a metabox with some custom fields - see attached screen #2), and created a custom content template with views to display those data;
i used toolset access to limit the serving of this part of the product only to selected groups - see attached screen #4;
the groups are created with the "WP Groups" plugin.
by now the system works, but i need to manually sync the group names and the checkboxes in the product edit screen, modifying each time the checkboxes list in the toolset CF group - see attached screen #3.
i'd like to dinamically auto-populate the "checkboxes" custom field with the names of the WP user groups created with the plugin "WP Groups", so if i change the name and/or add/delete some group, the system will always be automatically synced through the groups and the single products data access.
I visited this URL:
I expected to see:
Instead, I got:
Hi, let me make sure I understand what you would like to do. You want your custom select field to include an option for each Group. Groups are created by WP Groups. When a Group is modified, added or deleted, the changes should be reflected in the checkboxes custom field.
Is this correct? Which WP Groups API hooks should I rely on? You may need to check their documentation or ask their support team. hidden link
Here's what I would ask support, if you're not able to understand their API:
"I want to trigger some code whenever a Group is [modified, added, edited, deleted, whatever you want]. What action hooks should I be using from your API to trigger this code?"
When you have that information, I can provide some further guidance here.