Rev Slider doesn't work after update in Google Chrome

Hi. I’m trying to find the solution of a problem why Revolution Slider Events doesn’t work after update. I needed to downgrade back to 5.4.6.3.1 in order to get this example of event work.

revapi5.bind("revolution.slide.onloaded",function (e) {
	console.log("slider loaded");
});

I got this error Uncaught TypeError: Cannot read property 'bind' of undefined

The strange problem is that in Firefox worked well, but Chrome and IE showed the above error.

What could cause this?

You can see it here if you look into the console: http://18.197.183.31/webkamera/

Thank you.

Hello @Torbeneltempo,

Thanks for asking. :slight_smile:

As you have rolled back, I see revolution slider working on the website. https://cloudup.com/cmQBotuUCQy

Yes, I see the error message on dev console. Please try deleting Revolution Slider from Plugins > Installed Plugins and reinstalling the same from X > Validation > Extensions > Revolution Slider.

Please let us know how it goes.

Thanks.

I’ve reinstalled the plugin and still doesn’t work. Any ideas?

Hi There,

Thanks for the update!

Could you please send us your login details in a secure note so that we can have a look on to the issue.

Thanks!

secure note updated

Hello There,

It appears that you are using an older version of the theme. Could you please update to the latest versions?
Our latest versions are:

  • Pro theme 2.0.4

This latest release contains fixes for several issues so be sure to check out the changelog (http://theme.co/changelog/).

After doing the updates, always remember to clear all caches (if you are using WP Rocket, WP SuperCache or W3 Total Cache) when updating so that the code from the latest release is always in use. This will help you to avoid any potential errors.

Please let us know how it goes.

theme updated, but the error it’s still there.
I firefox console says

TypeError: revapi5 is undefined

Thanks.

Hello there,

It could be that your revapi wasn’t properly setup. Kindly double check your code in wp-content/themes/pro-child/js/custom.js

You can refer to the following tutorial on how to setup a revapi variable in your slider:

https://www.themepunch.com/faq/how-to-setup-a-revapi-variable-to-use-the-sliders-api/

If you still have problems, can you update the secure note with your FTP login details so we can take a closer look?

Hope this helps. Thank you.

I tried even with the demo ones from the rev slider backend
for example

revapi5.bind(“revolution.slide.onloaded”,function (e) {
console.log(“slider loaded”);
});

and got the same result.

Hello There,

I have checked your site again and I can see that the slider is already working. I can even click the next and previous slides. This is how I see it:

Please clear your site caches including your browser cache. You may need to use private browsing mode or incognito mode and test your site again.

Please let us know how it goes.

the slider that doesn’t work is http://18.197.183.31/webkamera/

Hi there,

It seems to be working on my end, but, you shouldn’t add your slider related javascript in custom.js file. You should add it within your slider’s custom javascript section. Since it’s needed to be wrapped by slider’s javascript declaration where revapi5 is initiated.

I’m referring to this script

//load webkamera only on carousel slide is visible
    if(a('#rev_slider_5_1').length){
        revapi5.bind('revolution.slide.onchange', function(event, data) {
            a('.tp-revslider-slidesli').each(function(i, obj) {a(this).find('.video-holder').css('background','none');});
            var dataSource = a('.active-revslide').attr('data-source');
            var bkgConstruct = 'url('+dataSource+')';
            a('.active-revslide').find('.video-holder').css('background',bkgConstruct).css({
                'background-size':'contain', 
                'background-position':'center center', 
                'background-repeat':'no-repeat', 
                'height':'100%'
            });
        }); 
    }

Thanks!

That was it, you’re the best. Thank you.

On behalf of my colleague, you’re welcome. Cheers! :slight_smile:

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.