Skip Navigation

[Resolved] Excluding ceratin posts from a 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 thread is resolved. Here is a description of the problem and solution.

Problem:

I've a custom content type created using Toolset Types called "offers". I'm surfacing these on a page on my site using a View.

However I want to exclude certain offers from this view. In the post fields I've added a checkbox "exclude from listing". If this is checked when entering an event, I want this to not display in the View. I'm thinking this could be achieved through a query filter, but I'm struggling to work out how.

Solution:

It depends on how you setup the custom checkbox field "hide from listing", for example, you can edit the custom checkbox field "hide from listing", option "Value to store" fill number "1", see screenshot hide-from-listing.JPG,

https://cdn.toolset.com/wp-content/uploads/2018/03/621231-hide_from_listing.JPG

Then in your view, screenshot:
https://cdn.toolset.com/wp-content/uploads/2018/03/621136-Screen_Shot_2018_03_01_at_21.19.19.png?x86419

You can setup the filter in view, like this:
Select items with field:

hide from listing is a number equal to 1

Relevant Documentation:

This support ticket is created 6 years, 10 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 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9: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/Hong_Kong (GMT+08:00)

Tagged: 

This topic contains 2 replies, has 2 voices.

Last updated by Paul Musgrave 6 years, 10 months ago.

Assisted by: Luo Yang.

Author
Posts
#621136
Screen Shot 2018-03-01 at 21.19.19.png
Screen Shot 2018-03-01 at 21.20.03.png

Tell us what you are trying to do?
I've a custom content type created using Toolset Types called "offers". I'm surfacing these on a page on my site using a View. However I want to exclude certain offers from this view. In the post fields I've added a checkbox "exclude from listing". If this is checked when entering an event, I want this to not display in the View. I'm thinking this could be achieved through a query filter, but I'm struggling to work out how.

Is there any documentation that you are following?
https://toolset.com/documentation/user-guides/filtering-views-by-custom-fields/

#621231
hide-from-listing.JPG

Hi,

It depends on how you setup the custom checkbox field "hide from listing", for example, you can edit the custom checkbox field "hide from listing", option "Value to store" fill number "1", see screenshot hide-from-listing.JPG,

Then in your view, screenshot:
hidden link
You can setup the filter in view, like this:
Select items with field:
hide from listing is a number equal to 1

#621873

Thanks this worked great

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