Skip Navigation

[Resolved] Filtering does not update results

This thread is resolved. Here is a description of the problem and solution.

Problem: Filters do not appear to be working on my custom search View

Solution: Activate AJAX updates in your View's settings, then check that the filters and pagination controls are added correctly. See the linked documentation below for more information.

Relevant Documentation:
https://toolset.com/documentation/user-guides/front-page-filters/
https://toolset.com/documentation/user-guides/front-page-filters/#2-1-custom-search-settings
https://toolset.com/documentation/user-guides/front-page-filters/#vfmh-adding-search-controls-submit

This support ticket is created 7 years 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
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 4 replies, has 2 voices.

Last updated by Joakim Blix Jaksland 7 years ago.

Assisted by: Christian Cox.

Author
Posts
#599440

I am trying to show a custom post with filtering (buttons) based on category. But clicking the buttons dont update the results.

Link to a page where the issue can be seen: hidden link

I expected to see: hidden link

Instead, I got: hidden link

#599617

I assume you refer to the AJAX updated search that hidden link uses?

To build the same with Toolset Views, you need to activate this in the Toolset View setting for the Front End Filtering. There are the options to set in order to use AJAX search results updating.

You can also consult this document: https://toolset.com/documentation/user-guides/front-page-filters/ https://toolset.com/documentation/user-guides/front-page-filters/#2-1-custom-search-settings https://toolset.com/documentation/user-guides/front-page-filters/#vfmh-adding-search-controls-submit

Your AJAX seems to trigger - I tested it and controlled the source.

But, there are some problems updating the results. Also I see the pagination fails as well which you added to the code.

I suggest to: - insert this view once in a single page, and remove all JS or CSS you added. Test it. - Then, if the issue persists, create a new dummy view to test with that one - If then the issue still persists, we need to know wether or not this also happens without any other plugin or theme. Please disable all plugins except Toolset and activate a default theme like Twenty Seventeen, then retest.

If the problem remains, I'll need to take a closer look.

#599673

Thank you mate, worked like a charm 😀
One more question: Im trying to make a digital asset management site for a client of mine. How can i make the download link on the custom post type that forces the browser to download the image instead of just opening it in a new window?

#600035

If you build your link tag in HTML, you can use an HTML 5 attribute in your link tag to specify that you want to trigger a file download:

<!-- will download as "awesome.jpg" -->
<a href="[wpv-post-field name='wpcf-your-image-field']" download="awesome.jpg">Download An Awesome Image</a>

If you need more technical implementation information, please create a separate ticket so we can address that on its own. Thanks!

#600116

thx for the help!