Skip Navigation

[Resolved] Stranger things after update to WordPress 5.3

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

Problem: I'm using SlickSliders with Views to create sliders for my site, but they don't seem to be working after updating to WordPress 5.3.

Solution: Be sure to use the jQuery namespace instead of $, or use a document ready handler to pass $ into a callback function.

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

Last updated by Serhii 5 years, 1 month ago.

Assisted by: Christian Cox.

Author
Posts
#1385479

Hi, my production site is hidden link but after the last WordPress update (version 5.3) I got issues, so I restored WordPress 5.2 and created the copy on subdomain hidden link for finding and fixing issues.

So,

Wordpress 5.2 - online-kazino.vip
WordPress 5.3 - 53.online-kazino.vip

What problems I have got:

Main page hidden link - all sliders work fine - hidden link
Main page hidden link - all sliders don't work - hidden link

The same problem on the single pages:

Review casino page - hidden link (hidden link)
Review casino page - hidden link (hidden link)

These sliders are a combination of Toolset View and SlickSlider (hidden link)

And I do not know what happened. Is it Toolset problem or SlickSlider or of both or something different?

Can you help me, please?

#1385501

Hello, I can see a JavaScript error in the console:

Uncaught TypeError: $ is not a function

I can see the problem here in some custom code for the Slick Slider:

$('.block-payment-slider').slick({

And again here:

$('.readmore-block').readmore({

Instead of $, it's best to use jQuery:

jQuery('.block-payment-slider').slick({
jQuery('.readmore-block').readmore({

Or, wrap your code in a document ready handler that receives $ as a parameter, like this:

jQuery(document).ready(function($) {
  // you can use $ in this function instead of jQuery
  $('.block-payment-slider').slick({
  ...and so on...
});

Please use these suggestions to fix the JavaScript errors and let me know if the problem is not resolved.

#1385591

My issue is resolved now. Thank you!