Skip Navigation

[Resolved] Update 2.9.4 interfering with pagination and filters

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

Problem:

The view was working correctly until I updated the plugin, None of the filters or pagination updates the items in the Toolset view.

Solution:

Since Views Ajax pagination and Ajax search form depends on JavaScripts, I suggest you try to fix those JS errors first, for example:

https://toolset.com/forums/topic/update-2-9-4-interfering-with-pagination-and-filters/#post-1381725

Relevant Documentation:

This support ticket is created 5 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
- 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 2 replies, has 2 voices.

Last updated by patrickM-18 5 years, 2 months ago.

Assisted by: Luo Yang.

Author
Posts
#1381591

I am trying to: Use the filters on my view and pagination. The view was working correctly until I updated the plugin.

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

I expected to see: The filters and pagination to change the URL of the page and AJAX load the matching items in the Toolset view.

Instead, I got: None of the filters or pagination updates the items in the Toolset view

#1381725
js-error.JPG

Hello,

Thanks for the details, I can see the problem you mentioned above, and I see lots of JS errors in my Chrome console, for example:

Uncaught TypeError: $ is not a function
    at bindModals ((index):642)
(index):709 binding 9393
(index):710 Uncaught TypeError: $ is not a function
    at bindModals ((index):710)
(index):777 binding 9395
(index):778 Uncaught TypeError: $ is not a function
    at bindModals ((index):778)
(index):845 binding 9397
(index):846 Uncaught TypeError: $ is not a function
    at bindModals ((index):846)

See screenshot JS-ERROR.JPG

Since Views Ajax pagination and Ajax search form depends on JS codes, I suggest you try to fix those JS errors first, for example:
1) Deactivate all other plugins, and switch to wordpress default theme 2019, and test again
2) If the problem is fixed, activate other plugins/theme one by one, try to locate the problem plugin, theme

#1382609

My issue is resolved now. For reference, solving the JS error fixed the AJAX problem. There was a conflict with loading jQuery because "$" was undefinted.
Adding this code to the loop solved the issue:

jQuery(document).ready(function($) {
// Code that uses jQuery's $ can follow here.
});

Thank you!