User in multiple groups can’t see posts with multiple categories

Hi, we have users in multiple groups, e.g. ‘town a’, ‘town b’, ‘town c’, etc.
We then have post categories which are restricted to members of the assigned groups.
However, if a user is in group: ‘town a’, and I add add post with categories ‘town a’ AND ‘town b’, the user cannot view the post. Can you please advise.

Posted in

Comments

3 responses to “User in multiple groups can’t see posts with multiple categories”

  1. Hi Tracy,

    In this case you don’t need to modify the code but instead alter the way you restrict your content.
    If an article needs to be accessible from all three groups members, then you can add another group let’s say towns and restrict it. Afterwards, each member of these three groups would also become member to towns group.
    As a result, you will still be able to restrict content to each of these groups but also allow them to access specific content through their common group.

    The group management and new group members can be added through your Dashboard under Users. You can select users in bulk and also add/remove them to/from groups also in bulk.
    Reference: https://docs.itthinx.com/document/groups/memberships/

    Kind regards,
    George

  2. Tracy Elford Avatar
    Tracy Elford

    Thanks for the quick response! Is there a way to customise the code to allow for the following:

    An article posted to groups ‘town a’, ‘town b’, ‘town c’

    A user who is only in group ‘town a’ still able to see the article when accessing the ‘town a’ category page?

    Thanks

  3. Hi Tracy,

    Welcome back to our support forum.

    That’s the normal process of restrictions applied with groups. When a post or taxonomy is restricted to more than one groups, then a user has access if he/she is a member of all the groups used for that restriction.

    From your description I’m assuming that you would expect it to grant access to any of the members of each group, but Groups plugins works the other way round, a user must be a member of each one of the groups used for that restriction. If you prefer, at least one group is needed to restrict access to a post or taxonomy.

    Kind regards,
    George

Share