Skip Navigation

[Resolved] Conditionally display code that determines access

This support ticket is created 7 years, 2 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 1 reply, has 2 voices.

Last updated by Minesh 7 years, 2 months ago.

Assisted by: Minesh.

Author
Posts
#573425

Hi,

I've got a post type where members can post articles they have written. They get the option to choose to tick off for "visible for members only" or "public" visibility, through a custom taxonomy.

This is easy to implement in the views section, but what if someone from the forum sends a link on for example email? It's only the view that is hidden, and not the post itself! Since the post type has a set layout, I can't make the layout visible for members only - as this will hide also the public articles!

My idea was to make an access shortcode that hides it, and make this access code conditional - so that it would only have an effect if the "for members only" is checked. Will this solution work? I've tried for a while, but struggle to make the conditional code make sense. The taxonomy is called: "synlighet" and the spesific option for members-only is called "kun-for-medlemmer"

Kind Regards,

Andrea Stykket

#573511

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

I need more information to understand your issue. Could you please explain with test example or few screenshot what information should be visible to public and what information you would like to hide when "for members only" field is checked.