• I’m asking around to a few plugin authors about this specific use-case. It looks to me like Content Control is very close…

    When a new member registers, the site will create a single post or page and assign them as the author/owner. So every user has a single page. We can inject CC shortcodes into the user posts.

    Members establish relationships. Think of Facebook-style “friends”, where you can only see a private profile (the above post/page) if you have a relationship.

    In this case, there are different types of friends. For now, think of these as roles.

    – Member2 can be in a Friend group with Member1. Everyone in the Member1 Friend group sees the same content on Member1’s page. This would be like the shortcode with the role=”subscriber,editor”, but role=”friend”.
    – Member3 can be in a Family group with Member1, and does not see data intended for Member1 Friends. So there would be another shortcode on the post with role=”family”.
    – Member3 has no relationship with Member2, there is no “friends of friends” relationship.

    After getting Friends and Family working, we will enhance so that members can create their own type. So by default there would be a Member1_Friend type and a Member1_Family type, but they might add Member1_CoWorker, and then assign that type to other members/friends.

    Roles don’t actually work here, because there can be multiple relation types for each member (Member1_Friend,Member1_Family…). It seems to me that in the shortcode PHP where you check for the role attribute, I might be able to substitute the handling for that with a check for a wp_user custom field called Relationship, to see if the current member2 includes Member1_Friend, rather than checking to see if the user role is subscriber or editor.

    Is there a filter hook in that code so that I can create a plugin/function that repurposes the “role” attribute?

    Any other suggestions for how this might be done with CC?

    Thanks!

The topic ‘Does CC fit this use case?’ is closed to new replies.