Your cart is currently empty!
Groups
Groups is designed as an efficient, powerful and flexible solution for group-oriented memberships and content access control.
It provides group-based user membership management, group-based capabilities and access control for content, built on solid principles.
Groups is light-weight and offers an easy user interface, while it acts as a framework and integrates standard WordPress capabilities and application-specific capabilities along with an extensive API.
Enhanced functionality is available via Official Extensions for Groups.
Groups is a WordPress plugin that provides group-based user membership management, group-based capabilities and content access control. It integrates standard WordPress capabilities and application-specific capabilities along with an extensive API.
Documentation
The official documentation is located at the Groups Documentation pages.
Features
User groups
- Supports an unlimited number of groups
- Provides a Registered group which is automatically maintained
- Users can be assigned to any group
- Users are added automatically to the Registered group
Groups hierarchy
- Supports group hierarchies with capability inheritance
Group capabilities
- Integrates standard WordPress capabilities which can be assigned to groups and users
- Supports custom capabilities: allows to define new capabilities for usage in plugins and web applications
- Users inherit capabilities of the groups they belong to
- Groups inherit capabilities of their parent groups
Access control
Access to posts, pages and custom post types can be restricted by group.
If access to a post is restricted to one or more groups, only users who belong to one of those groups may view the post.
Fully supports custom post types, so that access to post types such as products or events can easily be restricted.
- Built-in access control that allows to restrict access to posts, pages and custom content types to specific groups and users only
- Control access to content by groups: shortcodes allow to control who can access content on posts, show parts to members of certain groups or to those who are not members –
Shortcodes: , - Control access to content by capabilities: show (or do not show) content to users who have certain capabilities –
Shortcodes: , - Blocks: The Groups Member block allows to restrict the visibility of its content to members of selected groups.
The Groups Non-Member block hides its content from members of chosen groups.
The blocks can be nested to provide multiple layers of access control to content.
Easy user interface
- Integrates nicely with the standard WordPress Users menu
- Provides an intuitive Groups menu
- Conceptually clean views showing the essentials
- Quick filters
- Bulk-actions where needed, for example apply capabilities to groups, bulk-add users to groups, bulk-remove users from groups
Sensible options
- Enable access restrictions by custom post type
- An optional tree view for groups can be shown when desired
- Provides its own set of permissions
- Administrator overrides for tests
- Cleans up after testing with a “delete all plugin data” option
Framework
- Groups is designed based on a solid and sound data-model with a complete API that allows developers to create group-oriented web applications and plugins
Multisite
- All features are supported independently for each blog in multisite installations
Extensions
Enhanced functionality is available via official Extensions for Groups.
Groups is a large project that is providing essential functionality to tens of thousands of sites since 2012. By getting an official extension, you help fund the work that is necessary to maintain and improve Groups.
- Groups WooCommerce : Sell Memberships with Groups and WooCommerce – the best Group Membership and Access Control solution for WordPress and WooCommerce.
- WooCommerce Product Search is the essential extension for every WooCommerce store. It provides the best Search Engine and Search Experience for WooCommerce and is compatible with Groups and its access restrictions on products.
- WooCommerce Group Coupons : Automatically apply and restrict coupon validity for user groups. Offer exclusive, automatic and targeted discounts for your customers.
- Groups Drip Content : Release content on a schedule. Content dripping can be based on user account creation, group memberships and specific dates and times.
- Groups File Access : Allows to provide file download links for authorized users. Access to files is restricted to users by their group membership.
- Groups Restrict Categories : Features access restrictions for categories, tags and other WordPress taxonomies, including support for custom post types and taxonomies.
- Groups Forums : A powerful and yet light-weight forum system for WordPress sites.
- Groups Import Export : Provides import and export facilities around users and groups.
- Groups Newsletters : Newsletter Campaigns for Subscribers and Groups, also integrates with WooCommerce.
- Groups Gravity Forms allows to add users to groups automatically, based on form submissions.
- Widgets Control Pro : An advanced Widget toolbox that adds visibility management and helps to control where widgets are shown efficiently.
Get involved
You & Groups
Beta-testers and developers who need to integrate group-based features in their plugins and web applications: please use it and provide your feedback.
Feedback
Feedback is welcome!
If you need help, have problems, want to leave feedback or want to provide constructive criticism, please leave a comment below.
Please try to solve problems there before you rate this plugin or say it doesn’t work. There goes a lot of work into providing you with free quality plugins! Please appreciate that and help with your feedback. Thanks!
Stay informed or contribute
Follow @itthinx (or on Reddit, Mastodon, … ) for news related to Groups and other plugins.
Get development notifications, contribute code or open issues at the repository on GitHub.
Translations
Translations have been contributed by many from the WordPress community, via the GitHub repository Groups, the section for Groups on Translating WordPress or as direct contributions.
Where to get Groups
Groups is free. You can install it directly from your WordPress dashboard or download it from the Groups plugin page and install it manually.
Comments
2,691 responses to “Groups”
Hi, I have a question . When I create a specific group discount the result for that group does what on me regular_price , the result should be on SALE_PRICE that is my final price . As I can do to not apply the discount on sale Price
Hi Rubén, what plugin are you using for that?
Hi,
I am building a membership-based community using WooCommerce, WooCommerce Subscriptions, Groups for WooCommerce, Groups and Ultimate Member.
When a user buys a subscription they get added to a group (Basic Group/Standard Group/Premium Group). At the same time I assign them to an Ultimate Member role (basic-member/standard-group/premium-member). When they pause or come to the end of a subscription, they are removed from the group and downgraded to an Ultimate Member member role.
I managed to piece together the following code by looking back at old posts here. It seems to work, but I just wanted to check 1) there isn’t a better way to write it and 2) to understand why Groups_Group::read takes one parameter when the API document seems to suggest it should take two.
Thanks,
rt.—
function groups_add_um_role($user_id){
if ( ( $group = Groups_Group::read_by_name( ‘Basic Group’ ) ) &&
Groups_User_Group::read( $user_id , $group->group_id ) ) {
update_user_meta($user_id, ‘role’, ‘basic-member’);
} elseif ( ( $group = Groups_Group::read_by_name( ‘Standard Group’ ) ) &&
Groups_User_Group::read( $user_id , $group->group_id ) ) {
update_user_meta($user_id, ‘role’, ‘standard-member’);
} elseif ( ( $group = Groups_Group::read_by_name( ‘Premium Group’ ) ) &&
Groups_User_Group::read( $user_id , $group->group_id ) ){
update_user_meta($user_id, ‘role’, ‘premium-member’);
} else {
update_user_meta($user_id, ‘role’, ‘member’);
}}
add_action(‘groups_created_user_group’,’groups_add_um_role’, get_current_user_id());
function groups_remove_um_role($user_id){
update_user_meta($user_id, ‘role’, ‘basic-member’);
}add_action(‘groups_deleted_user_group’,’groups_remove_um_role’, get_current_user_id());
Hi Richard,
please use the forums for these questions.
Please have a look to the API: Groups_Group::read and the add_action function.
Thanks!Hi Antonio,
I can’t see a forum for questions about the Groups plugin. Could you kindly share a link to it?
I read the API. My code works. I just wanted some reassurance I have written it correctly, as I am not a developer.
Thanks,
rt.Sorry Richard, still has not been created the forum 🙂
Your code seems correct, except the call to ‘add_action’ and functions parameters. I hope this can help you:
add_action( 'groups_created_user_group', 'groups_add_um_role', 10, 2 );
add_action( 'groups_deleted_user_group', 'groups_remove_um_role', 10, 2 );
Your ‘groups_remove_um_role’ and ‘groups_add_um_role’ functions have two parameters: $user_id and $group_id
function groups_add_um_role($user_id, $group_id){
....
$group = new Groups_Group ( $group_id );
$group_name = $group->name;
....
}
function groups_remove_um_role($user_id, $group_id){
...
}
Regards,
Antonio B.Thanks Antonio.
As I understand your response, you are suggesting that I change my ‘groups_remove_um_role’ and ‘groups_add_um_role’ functions to take two parameters: $user_id and $group_id.
Given that, is there an equivalent of get_current_user_id() for groups, so I can pass in the current group, as the point of my code is to assign a user to an Ultimate Member role (basic-member/standard-group/premium-member) at the same time as they get added to a group (Basic Group/Standard Group/Premium Group)?
Thanks,
rt.Hi Richard,
the second parameter $group_id is the current group added/removed.
You have more information available in Groups API.
Thanks,
Antonio B.Ah ha! I think I just proved a little knowledge can be a dangerous thing.
I thought the third (10) and fourth (2) parameters where the parameters I needed to pass in. I see from http://codex.wordpress.org/Function_Reference/add_action that in fact the third is used to specify the ORDER in which the functions are executed and the fourth is a COUNT of the parameters taken by the hooked function, i.e. groups_created_user_group and groups_deleted_user_group.
Thanks Antonio for the help (and WordPress lesson). My code now reads:
function groups_add_um_role($user_id, $group_id){
if ( $group_id == ‘2’ ) { // 2 is the id of the Basic Group
update_user_meta($user_id, ‘role’, ‘basic-member’);
} elseif ( $group_id == ‘3’ ) { // 3 is the id of the Standard Group
update_user_meta($user_id, ‘role’, ‘standard-member’);
} elseif ( $group_id == ‘4’ ){ // 4 is the id of the Premium Group
update_user_meta($user_id, ‘role’, ‘premium-member’);
} else {
update_user_meta($user_id, ‘role’, ‘member’);
}}
add_action(‘groups_created_user_group’,’groups_add_um_role’, 10, 2);
function groups_remove_um_role($user_id, $group_id){
update_user_meta($user_id, ‘role’, ‘member’);
}
add_action(‘groups_deleted_user_group’,’groups_remove_um_role’, 10, 2);
Now looks better 😉
Thanks,
Antonio B.
How do I allow a user group access to only use a certain plugin?
Hi Chris,
this feature is not available. You can use Groups API to create your own solution.
Regards
I need to have a WP role for each user group to integrate the content restriction to other plugins which can only restrict access by roles. How can I do this?
You can’t unless you create a specific solution for that. Is there anything in particular you’re missing from the access restrictions that Groups itself provides?
Yes, my forum plugin uses dynamically generated permalinks and I cannot restrict access to these pages since there is no WP page.
Many plugins have the ability to restrict access to certain forums or other parts of a plugin by roles. I have set up Groups for Woocommerce to give access privileges.
But when I try to restrict access with my plugin I find no way to do this, since I think it has to be done with roles. Only thing I have is Groups and capabilities.
Tell me if you can figure out a solution.
Would it be possible to write an extension for Groups that would assign roles to Groups in addition to capabilities? This would make Groups compatible with many other solutions???
Yes, I have found no way of restricting access to dynamically created permalinks. They have no real page/post equivalents. The plugin that I use could do restriction by roles, but I have Groups for Woocommerce set up and as far as I know I can only control my customers abilities.
Could a plugin be created for adding roles for each group?
Ok thanks, roles by group would really be redundant but what would make sense and is already possible is that you assign the needed capabilities to the groups involved.
Hi Antonio , I have a question and would like to enlist your help . I have an MSRP price web strikeout and a price that is with the discount , you can see the example http://www.growermark.com/tienda/extractor-rvk-sileo-125l-323m3h – The problem is that when I assign the discount that I created for a particular group , makes me the discount on the crossed out price and it is wrong , as it should do so by taking the bid price of the product. How I can fix this?
If correct , but many of the available opociones not explained in Spanish and I have to go about doing translations with google .
We will review the admin translations for next update.
Thanks!
Hi, I’m using a questions and answers plugin (CM answers) that allows restricting access by user roles. I have set up groups vie groups for woocommerce.
Now I need to restrict access to the Q&A plugin page /answers to a group, but I can only do this with roles. The answers page is created with a slug, so I cannot normally restrict access to it via group capabilities.
How can I solve this? Can I assign a user role to each group?
Hi,
if you have selected ‘Question’ in Groups->Options you should have an ‘Access Restrictions’ box in your questions edit page.
Regards
ok , when a version in Spanish ? 😉
Hi Rubén,
spanish version is available. When you install Groups, if your wordpress version is in spanish you’ll see Groups in spanish.
cheers
Good afternoon , first congratulations for the pluggin , is a very good tool. I had a doubt about the capabilities that each group , do you have a list detailing the meaning of each of the skills ? Could really know the meaning of each , I’m Spanish and taking a brief explanation would be interesting. Thanks in advance.
I found it , sorry but had not seen the link. http://www.itthinx.com/documentation/groups/shortcodes/
Hi Rubén, the new documentation is at http://docs.itthinx.com/document/groups/ – thanks for the kind feedback on the plugin 🙂 Cheers
Hi!
I’d tried to set up WooCommerce shop pages that are only visible for Customers. I used the default Registered group for that, created a Registered Capability, assigned it to the group and activated it in Options. Pages with Enforce read access ‘Registered (Registered)’ are now visible for normal Users but not for Customers. Is that somehow possible?
Or is there a better way that automatically every registered WooCommerce Customer can view the shop pages (and non-users not). Hope you understand my question :).
Thanks!
Hi Wouter,
The customers should also be able to see those pages if they are logged in. As a user account is created, the user would also belong to the Registered group which then opens up access to the pages.
Cheers
Hi there.
Just installed Groups and WooCommerce groups on a Multisite install.
The groups plugin activated fine on the top level site, but when I try to activate it on a subsite, I get the following error. (Saw similar comments about very large queries on the WordPress.org plugin support page).
Plugin could not be activated because it triggered a fatal error.
Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 71 bytes) in /home/blogprss/public_html/wp-includes/wp-db.php on line 948Thanks in advance for your help!
JenniferHi Jennifer,
it’s a problem with your memory limit. In Woocommerce->System Status you can see your memory limit ( We recommend setting memory to at least 128MB )
Regards
I am able to use shortcode to show specific content to members and non-member. Thats working fine.
I want to inform non member that this content is restricted and that they must buy or log in. In order to log in I am linking them to woo-commerce my-account page.
I am not quite sure if this is the best way to do it.
Is there any other way to show to non member login fields?
And I have an other problem. I restricted a page which doesnt accept shortcodes. So I restricted it entirely with group plugin. That worked.
But if user is not logged in the page tries to load and nothing appears. I would like them to redirect to login or displat some information. But as this page doesnt accept shortcodes I cant.
Is there any other way?
Hi,
if you need to add the login form in a page, this post can help you.
To redirect to another page Groups 404 Redirect plugin.
Regards
I am using group plugin together with woo-commerce group extension.
How can I make user who is not a member redirect to login instead?
Hi
I have some users in active directory.and i have a hierarchy of groups in that with specific roles to specific users Like administrator role to certain users some user are having editor role.
what I want is to integrate this with active directory so that if I bulk import the users or groups it maintains the hierarchy which is made in active directory with the roles assigned for them.
Iam using Active directory integration plugin and this is working fine https://wordpress.org/plugins/active-directory-integration/
Thanks in Advance
FiyasHey!
I have specific posts that i would like to restrict per user (not groups or capabilities).
Is there any chance to succeed this feature?
Best wishesHi,
you can create a group and assign the user to this group (a group with only one member).
Regards
Hi – I currently have a site running with Groups and Groups for Woocommerce. I need to build a 2nd site on the same server and have managed to use the same database and also the same MySql user table so that user info is shared. I did this by adding the following to the wp-config file:
$table_prefix = ‘subsiteprefix_’;
define(‘SHARED_USER_TABLE_ROLES_PREFIX’, ‘mainsiteprefix_’);
define(‘CUSTOM_USER_TABLE’, ‘mainsiteprefix_users’);
define(‘CUSTOM_USER_META_TABLE’, ‘mainsiteprefix_usermeta’);
This, however, doesn’t bring across my groups settings and assigned capabilities – can you let me know if I can use this method to connect all the group capabilities, and, if so, which tables I need to include?
Thanks for any help!Hi Rob,
I wouldn’t recommend it. The arquitecture of the system isn’t supporting this way of operation and I can imagine that you will find a lot of difficulties synchronizing things between the two sites.
Would you mind explaining why exactly you need to have this second site using the data from the first one? Wouldn’t a multisite setup be more appropriate for what you intend to do?
Cheers
Yeah – it’s a spin-off site that will sell photos to members from the original site. We’re on the same server but using a different install to try and keep the resource-hungry image library away from the main members site…
If we created a multisite WP install – could we synchronise the data more easily between the 2 sites?
Hi,
Thanks for including a nice API documentation with your plugin.I’m trying to restrict access to posts so that only users with ALL the specified capabilities can access the page. Currently the plugin allows users who have ANY of the specified capabilities access a page.
In other words, I need to restrict a page/post so that only users who are part of both GroupA and GroupB can see it.My use case is this: I need to restrict access based on groups which inherit capabilities, like employee, management, upper management. The plugin can do this great. But I also need to restrict further on location; users in the New York group need to see different content than users in California group. And users will always be in both one of the location-based groups and one of the employment-level groups.
In the class-groups-post-access.php file, I see code which is commented out which would make the plugin behave in the manner specified above (just below the comment “The following is not correct in that it requires the user to have ALL capabilities:”
The “user_can_read_post” function would also have to be slightly altered in order for it all to work right this way.Would it be possible for you to add an extra option or something (either globally or on a page-level basis), to require users to have ALL the specified capabilities in order to access a page, rather than require users to have ANY of the specified capabilities?
If this jives with your vision of the plugin, I could even do the development.
Thanks.
Hi,
For this case I would recommend you to override the filter with your customized implementation. You would remove the posts_where that Groups adds and substitute it with your own.
One important note here, if you are going to do that, you should know that the access restriction model is very likely going to change in Groups 2.x – a switch from access restrictions based on capabilities to access restrictions directly based on group memberships. For your case, I would assure that you have groups in place that can be mapped to the capabilities, once the new model is used, it will make it easier for you to keep your setup up-to-date.
Cheers
I am having difficulty with a sub-navigation menu showing up on our site. The sub-nav menu item is based on a post Category. Therefore there is no ‘page’ for this menu item and no place I can find to modify it’s permissions. The sub-nav shows up fine when logged in as admin, but I have Groups set to ‘Admins override…’. How can I go about have post Categories available in the sub-navigation menu?
BTW, if I enter the address to the post Category page manually, the user is able to view the page fine. It just doesn’t show up as a menu item.
Thanks for your help.
Hi, you can add these as custom links, i.e. under Appearance > Menus > Links indicate the full URL and it won’t be “affected” by the access restrictions. I.e. you can add it as a Link indicating the full URL and set a link title accordingly, if you visit the link as an authorized user it will show up the content. Do you see what I mean?
We are a happy user of the Groups plugin.
Now I would like to explore if I can take advantage of groups in combination with our https://wordpress.org/plugins/widget-logic/ plugin to restrict visibility of some widget to logged-in users.
How would I use the API?
Thanks,
FrankSorry if this has been answered before but I can’t see a manual or an easy way to search.
My simple requirement is to restrict some content to only be visible to non registered users i.e. not a member of any group. I thought the following would work but it doesn’t:
[groups_non_member]
Call to join would go here
[/groups_non_member]
Any thoughts?
Hi Graham,
You need to specify the group – here’s an example:
[groups_non_member group="Registered"]
You're not logged in.
[/groups_non_member]Cheers
Hello,
I have a “archive-galeries.php” file.
I set a menu item “Galeries” as a link (my-site/galeries) in my menu.
All my post in my archive have restricted access to “Premium group”.
But Galeries menu item is still visible.
So when user in groups “Simple” click in the menu, they don’t see any post of this archive, but see “No article” string (that I set in my archive template).
How to restrict menu item visibility to only “premium”?
Cheers.Do you mean this piece of code?
$result = false;
require_once(ABSPATH . “wp-includes/pluggable.php”);
if ( $group = Groups_Group::read_by_name( ‘Registered’ ) ) {
$result = Groups_User_Group::read( get_current_user_id() , $group->group_id );
}
return $result;But where to put it to restrict visibility of a menu item?
I’m sorry I don’t understand.
I put this code in the menu item visibility field but get an error.true! You can use
current_user_can('read');
thanksIt works like a charm 🙂
Perfect!
can I keep search engine spiders and bots out of Groups protected cotent which I don’t want crawled and indexed…?
thanks
Hi Iain, they won’t even see the content if it is restricted.
Apologies if this is covered but I cannot see this in the documentation. I would like to show ‘non-members’ only certain elements of a page e.g. intro but restrict further content of the same page to paying members. Is this possible via this plug in?
Many Thanks
Thanks Antonio. What is the correct format when you need to specify multiple groups? I understand they should be comm separated but I can’t get that part to work.
Thanks
I have custom post with custom fields.
I would like to restrict visibility to custom fields. Is there a way to restrict visibility with the shortcode in template file?
CheersHi,
you can use something like this:
$user_id = get_current_user_id();
if ( $group = Groups_Group::read_by_name( 'Registered' ) ) { // if the Group exists
if (Groups_User_Group::read( $user_id , $group->group_id )) { // if the user_id belongs to this group
....
}
}
Also you have available the Groups API.
cheersAwesome thank you for your help I finally use:
can( ‘premium’ )) : // if the user has the capability
?>perfect!
I would like to override access to users with author role.
Is that possible?
Or should I include all capabilities for each author?Hi,
you could:
– create a group with a capability (e.g. ‘GroupA’ with capability ‘CapA’)
– Assign this group to the authors (in Users list you have a bulk action above the table)
– Then restrict posts/pages to this group.
RegardsThank you antonio
I created a new capability and I added this capability to my authors group.
Thank you antonio.Just to be more clear: I have Group “Author” where I added all capabilities of others groups to allow authors to have full access.
🙂
Hello,
I restricted posts to a group.
I use categories widget to list categories included the number of posts that belong to each categories.
For now, the number counts all posts of a categories and I would like to display the number of posts that group users are able to see.Hi,
true, we will resolve it in future updates.
Thanks!Hello, I would like to know if the bug was resolved 😉
I’m trying to Import users via a tab-separated TXT file using the ‘Groups Import Export’ extension. Upon clicking the button, the page displays the following error right away at the top of the page…
Error on line 1, ajd@egbubs.net is not a valid email address.
0 valid entries have been read.
1 entry has been skipped.
0 users have been imported.
0 users have been updated.How is that not a valid email address? I’ve been using it for literally 7 years?! What’s going on here? Any help would be appreciated. Thanks.
Is there a way that the ‘Groups’ plugin can restrict access to navigation menu items?
Thanks Antonio. That answered my question. It sounds like if the page has group restrictions assigned to it from Groups, then any Appearance > Menus items based on that page will also be restricted.
Exactly, regards!
I have installed the groups plugin. Set two different groups. I want to restrict retail buyers from viewing wholesale products. I set a whole sale product at the wholesale buyer restriction. bur the product still does not show up. I am using woocommerce for my products.
Hi,
you can send us dashboard admin acceso to support at itthinx dot com and we’ll have a look (please indicate this comment in the email).
cheers
I am trying to use the groups plugin shortcodes to create ‘teaser’ pages that either
1)show a snippet to logged in users not in the specific group or non logged in users
or
2)completely different text to those in the nominated group.This works fine for users logged and shows the page differently on the user group membership but displays nothing for casual browsers.
I have been through the docs. What am i missing here…
Hi Chris, can you provide an example of how you have it set up currently please?
Hi Kento
Tracked the problem down to some random html tags embedded by the user somehow…
Your product works just fine! 🙂
I’ve set up a product, created and allocated a group to it, but when payment is completed, the membership is not assigned to the user. What could be wrong here?
ThanksHi,
please be sure you have ‘Processing’ as ‘Add users to or remove from groups as early as the order is …’ in Woocommerce->Groups.
cheers
We have an issue of needing to restrict number of times a user gets access to a page (to view paid content). Is this in anyway possible to restrict? To put a “number of credit” on a group, so when credit is reached/used up membership of the group ends.
Regards,
MetteSorry,
this feature is not available in the plugin. If you need to create your own solution, you have available Groups API.
cheersHi Mette, it’s an idea worth exploring. What kind of content do you want to restrict access to? I’m asking to see if the content container or storage mechanism could be used to limit the number of times it can be viewed, or if it’s necessary to leverage a (currently unavailable) feature in the Groups framework.
Any idea how display different menu items in the nav based on what group the member is assigned to? Would really love this functionality.
I have differnt woocommerce products for members and non-members.
I would like for my member to no longer see the products for non-members.
Is this possible?Yes,
in your product edit page you have a ‘Access restrictions’ box to restrict access.
cheers
Am I doing something wrong? Please help.
[groups_can capability=”info”]
My group members have info capability but they can not see this.
[/groups_can]And:
[groups_non_member=”Registered”]
Every user can see this. My registered users can see this text.
[/groups_non_member]I tried different combinations but nothing works:
[groups_can capability=”edit_posts”]
I gave my group edit_posts capability. It did not work
[/groups_can]And:
[groups_member group="1"]
It did not work.
[/groups_member]Hi Jade,
Here’s an example you can use, you need a Donut group that has the donut capability and the user viewing the page should be logged out or logged in and be a member of the Donut group:
[groups_can capability="donut"]
You can donut.
[/groups_can][groups_non_member group="Registered"]
You're not logged in.
[/groups_non_member][groups_member group="Donut"]
You're in the Donut group.
[/groups_member]
Cheers
This plugin looks as if it’s very easy to use, but I there are 2 features I would love to see:
1. Ability to manage/group users at the Super Admin level under the Network Admin area
2. Ability to create groups based on user meta (NOT just capabilities)Hi Dan,
Thanks for the suggestions. I agree with #1 and would like to see that, too. For #2 could you explain a use case for that please?
Cheers
For suggestion #2: I have users being registered and choosing a specific day of the month. The Day of the Month field is created by using custom user meta. I would like to create different user groups based on the Day of the Month. A user that is registered with the value of 1 would be in the Day One group, the user that is registered with the value of 2 would be in the Day Two group, and so on. The end goal is to sync each group with a Mailchimp or Constant Contact list.
Also, is suggestion #1 in the development?
Hi Dan,
Thanks for explaining that, if you just want to sync the users to MailChimp maybe eggemplo’s Groups2Mailchimp would be sufficient?
On #1 yes we’re working on that, can’t give an ETA though.
Cheers
When using get_posts($args); the private posts disappear from the loop. Is there a way / loop to show the posts as a title list but get restricted when they access the main post page?
You could disable the filters that Groups uses and add your own to reduce the content displayed to the title. See http://www.itthinx.com/documentation/groups/api/ for examples and API docs please.
Are there any easy ways to show widgets based on user groups / conditions?
Hi Wayne,
Thanks for asking, I’ve replied already on Twitter but since you’ve already posted here and it’s a good question:
Currently it’s not implemented as an option on the admin user interface, you would have to implement it using Groups’ API and a way that allows to show widgets based on conditions such as https://wordpress.org/plugins/widget-logic/ – I think it lets you evaluate code directly so you wouldn’t have to implement the whole logic behind it …
Cheers
Can you please either disable access controls on private post types by default, or give us the ability to control which post types receive access controls via the options page?
Thanks for asking Tim but you already have that option under Groups > Options 🙂
We don’t though. Private post types don’t show up in this list, but access restrictions are on by default for them. The problem is line 226 of lib/admin/groups-admin-options.php which only pulls in public post types for the list of checkboxes. There’s no way to deselect private post types.
Thanks for pointing that out Tim, I’ll take that into account for review.
Hi,
I’m wondering why this wont work.Content is shown regardless of group membership.
I need to restrict content at a theme level, I’m unable to find how this can be done in the documentation.
Thanks in advance,Is there a way to add pagination and search in a fronted displayed list of users? or can someone explain how to do it?
Thanks.Is there a way to have access controls be disabled automatically for non-public post types? I have several hierarchical private custom post types with thousands of posts each, and having access controls on edit.php really slows down page load time (I’ve made the post types public and disabled access controls, just to see the difference). The options page currently only shows public post types.
Thanks Tim, this sounds familiar in case you’ve already gotten a reply, but I’ve taken note to review and add a possible option for that.
Looks like I figured it out. i didn’t realize you had to put the group name in the not_member shortcode too 🙂
OMG I just spent 4 hours trying to do the same thing!! Thanks for posting your findings! If it wasn’t for me reading your post I would have never known.. Who would have thought you had to include the group name in the not_member shortcode too! You would think this would be clearly stated on this page.. Anyway many thanks!
Thanks, we’ll review the documentation.
cheers
Is there some way to expand WP registration that integrates well with “Groups”? I’d like to be able to use an expanded registration plugin with Groups instead of trying to use S2 Membership which doesn’t play nicely with Woocommerce.
TIA.
DaveWhen I’m logged in as a paid/premium user (i use the woocommerce extension), I can see the content within the groups_non_member shortcode. I’d like this to be hidden so that it’s only shown to non-members and people not logged in. Why is it still showing?
How exactly are you using the shortcode please?
I am puzzled about the purpose of a parent group. I would expect that adding a user to a group, would automatically add them to the parent group. But this does not seem to be the case. This feature is desirable in my application (providing Mandarin Chinese classes, where multiple classes share the same online materials, but have different groups of students). So I decide to add the feature by hooking the ” action.
[code]
function groups_created_user_group($user_id, $group_id) {
$group = Groups_Group::read( $group_id );
$parent_id = $group->parent_id;
if (!empty($parent_id)) {
Groups_User_Group::create( array( ‘user_id’ => $user_id, ‘group_id’ => $parent_id) );
}
}
[/code]So I have two questions
1) What is the parent ID for?
2) It there a better way to make it work?Thanks
Hi,
user is not automatically added to the parent group, but capabilities are inherited. So if you create as ‘Alumns’ group with capability ‘alumns’ and a ‘Chinese’ group (with ‘chinese’ capability) with parent ‘Alumns’.
If you have a restricted post to ‘Alumns’, this can be readed by ‘Alumns’ and by ‘Chinese’.
If you have a restricted post to ‘Chinese’, this can be readed by ‘Chinese’ but not by all ‘Alumns’
cheesThanks!
I get it.
Now I have a follow up question.
Is it possible to have multiple parents?
I would like my classes to have the capabilities of one parent group, and belong to a calendar quarter to make it easier to count the number of students per quarter.Sorry, you can only have a parent. You should add your classes to several groups.
cheers
I am using this plugin to restrict access to mandarin lessons on my site. We have three courses and students register for ten week classes covering one of the courses. For example, the course name is “ML1” and the class name is “2015/2A-ML1”. Corresponding to the classes there are groups with the same name (eg “2015/2-ML1”) with a parent named “ML1”. In order to verify access privilege, we hope to check if the user is a member of the parent group (eg “ML1”). I thought that Groups_Access_Shortcodes::groups_member() would provide this functionality, but it does not. I can probably hack something together, but it seems like there must be some useful API that you guys are already exposing. Thanks for the great plugin! — especially if I can get this feature to work.
Hi,
Sure, please have a look at the API section of the documentation. Many thanks for your feedback on the plugin and don’t hesitate to ask if you have questions on the API usage.
Cheers
I’ve installed the Groups plugin. When I create a new post using shortcodes to control content visibility the shortcodes show up in the wordpress new post notification emails.
[groups_non_member group="vip"]
[/groups_non_member]
What plugin are you using to produce these emails? The plugin seems to skip the shortcode evaluation of WordPress when it prepares the content it is sending. Unless that’s intended, it’s a bug in that plugin.
Hi, I’m using both Groups and WooCommerce Groups. I’m using the combination to limit access to specified posts to Members. I have a “Recent News” area on my home page that lists posts in specified categories. Some of them are for members only, some open to everyone.
Is there a way to show an “indicator” that informs the site visitor a specific link is for “Members Only?”
Right now, I’m using the Groups 404 Redirect. If they click on it, they are directed to the “hey, you need to be a member” page. But displaying an indicator would be ideal.
Imagine something like this…
http://mtac.spidercreations.net/wp-content/uploads/2015/02/member-content.jpgSuggestions?
Hi Steve,
You could modify the template that produces your “Recent News” area so that it includes that indicator based on whether access restrictions are in place. If
Groups_Post_Access::get_read_post_capabilities( $post_id )
is not empty, then there are access restrictions in place.Cheers
I apologize in advance for my inability to decipher the API. Unfortunately I’m very new to it and don’t know what to look for much less apply. I have a group titled Premium. How do I use the API to restrict access within my theme? Specificity would be greatly appreciated. Is it anything like:
Restricted content Public ContentTIA
Antonio,
I am trying to submit a new topic that I need support with and when I login to my account it says I cannot post a new topic. It is in regards to Affiliates Permanent.
Please help!?
Wendy
Hi Wendy,
When do you purchase the product? if more than one year ago, the premium support is over. you should renew your license.
Regards,
Antonio B.Do I just purchase the software again or how do I renew my license?
Yes, you need to purchase the software again.
Regards
Leave a Reply