Skip Navigation

[Resolved] Display filter results for custom field

This support ticket is created 3 years, 4 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
- 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)

This topic contains 4 replies, has 2 voices.

Last updated by Luo Yang 3 years, 4 months ago.

Assisted by: Luo Yang.

Author
Posts
#2264665
Screenshot 2022-01-12 at 15.48.17.png
Screenshot 2022-01-12 at 15.47.41.png

I posted this question a few weeks ago and received the following information found here: https://toolset.com/forums/topic/creating-a-view-without-a-search-to-display-items-assigned-to-a-custom-post-type/

I have followed the steps in the thread above but when I add a shortcode to display the filter, it displays all of the listings instead of just the ones assigned to a specific broker. So I have got the listings to display but it seems that the filter is not working.

The settings for my filter and shortcode can be seen in the images attached.

The link to the page where the shortcode is sitting is: hidden link

Please advise on where I am going wrong here - do I have to go and re-assign each broker now that I have added values to the custom field or what?

#2265301

Hello,

Yes, you are following correct document:
https://toolset.com/documentation/legacy-features/views-plugin/passing-arguments-to-views/
The problem you mentioned above is abnormal, please check these:
1) In case it is a compatibility problem, deactivate all other plugins, and switch to WordPress default theme 2021, deactivate all custom PHP/JS code snippets, and test again
2) If the problem still persists, please provide database dump file(ZIP file) of your website, you can put the package files in your own google drive disk, share the link only, also point out the problem page URL and view URL, I need to test and debug it in my localhost, thanks
https://toolset.com/faq/provide-supporters-copy-site/

#2265361
Screenshot 2022-01-13 at 10.19.04.png

Hi there

Thank you for the reply. I have tried step one where I disabled all other plugins and themes and still have the problem.

I followed step two but cannot complete this because there is an issue with the host - the site is not hosted with us so I cannot really make any changes that side. Please see image attached.

Can I give you access to the current site to see if you can find the issue there?

#2265399

Please provide your website credentials in below private message box, also point out the problem page URL and view URL, thanks

#2266121

I assume we are talking about the custom checkboxes field "Broker" and post view "Derek Escher View Jan 2022 V3"

I have done below modifications in your website:
1) Edit the post view "Derek Escher View Jan 2022 V3":
hidden link
in section "Query Filter", change the filter to:
Select items with field:
Broker is a string equal to VIEW_PARAM(broker)

2) Edit the page:
hidden link
Replace the post view's shortcode with below:
[wpv-view name="derek-escher-view-jan-2022-v3" broker="Jim Ross"]
In this case, it needs to use option title as attribute value

Test it in frontend:
hidden link

It works fine.

Please check if it is fixed, thanks