First of all, I really love my switch to the Memberships 2 plugin. Love to work with that!
I'll present as clearly but short as I can. Here's what I'm working on (site is open for now:slight_smile:
I'm building a site in Norway for alternative practitioners. Two main functions of this site.
• To list practitioners, being able to filter them
• To display a user profile for them
The CPT, filtering, list views and profile pages is built using the complex Toolset plugin series. (https://wp-types.com/)
It's fine to set up CPT to display the profiles with custom fields. It's also fine, by using Toolset, to add frontend forms for the CPT.
But here's my dilemma:
• If a user signs out of the membership, how can I hide their profile/CPT?
A CPT is not connected to a user any other than as an author. Could that be a method? That CPT post does not know about any membership status.
In Toolset plugin, there are conditional output functions without programming using their plugin interface, like here: https://monosnap.com/file/Oqss4TFNl7cjBf2fcRgLOsCppbNOcK
I was thinking there was some custom field having a status for membership valid or not. But still, when adding this to the loop for the CPT list, it's not connected to who the post belongs to.
Hoping this makes sense.
What I would like to acheive is when users either sign out or don't pay the membership, their CPT profile posts go offline on the site.