Skip Navigation

[Resolved] Best way to make an exception for single post view?

The Toolset Community Forum is closed, for technical support questions, please head on to our Toolset Professional Support (for paid clients), with any pre-sale or admin question please contact us here.
This support ticket is created 6 years, 9 months ago. There's a good chance that you are reading advice that it now obsolete.
This is the community support forum for Types plugin, which is part of Toolset. Toolset is a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients and people who registered for Types community support can post in it.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 10:00 - - - - -
- - - - - - -

Supporter timezone: Africa/Cairo (GMT+02:00)

This topic contains 1 reply, has 2 voices.

Last updated by Mohammed 6 years, 9 months ago.

Assisted by: Mohammed.

Author
Posts
#630333

Tell us what you are trying to do?
I have a post type of staff/team members which is publicly queryable and clicking on a staff member takes the user to a post layout for that staff member. These staff members have a taxonomy of "groups" (management, operations, etc.). All of this is working great so far.
Now the client wants to make one of those groups (operations) an exception to single post view so they can only be shown as a list. I'd rather not create a whole new post type for that group to not be publicly queryable. I can easily make a different content template for that group without links to their post/profile and maybe put redirects/no index/etc on those staff members but this seems like a somewhat inelegant solution.

Is there a better solution that might be less work for me, and make this more sustainable for future use of the website?

Is there any documentation that you are following?
Just the basic docs for types/views. So far haven't found an example of what I'm looking for.

Is there a similar example that we can see?
Not that I can think of. I suppose this could be done with a hierarchy post relationship where each group of people is associated to either a publicly queryable or not publicly queryable parent. At the time I created this post type, naming a taxonomy "groups" seemed like a logical way to separate them as they are.

What is the link to your site?
hidden link

#630552
shot1.png

Hi,

You can differentiate between the available posts using the taxonomy you already use.

There are many ways to do that.

-You can add a query filter to include/exclude specific taxonomies. check this screenshot (shot1)
Documentation:
https://toolset.com/documentation/user-guides/filtering-views-by-custom-fields/

-You can do the same in a view using conditional if. check screenshot (shot2)
Documentation:
https://toolset.com/documentation/user-guides/conditional-html-output-in-views/

Thanks.

The forum ‘Types Community Support’ is closed to new topics and replies.