• Hi,

    I’ve update the plugin and now it does’nt work.

    Because It has a conflict with another plugin: W3 Total Cache.

    If i minififed the js with W3 Total Cache, Slide Anything is breaks.

    Have you any idea?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author simonpedge

    (@simonpedge)

    A few thing you can try:
    – Re-save the SA sliders you created previously – edit each and Save/Update
    – If that doesn’t work, can you exclude specific plugins from minification? If so exclude Slide Anything plugin and see if your SA sliders work. This will tell us if in fact there is and issue with minification and SA.
    – Also with the W3 Total Cache can you get a list of minified JS files – I’m wondering if there is another plugin also using Owl Carousel that can be clashing? i.e. 2 copies of the “owl.carousel.min.js” file.

    We’ve also had the same issue with BWP-Minify. Turns out it is the test for jquery that is causing the problem. In slide-anything-frontend.php, at the bottom where the script is included to activate a particular slider, it tests:
    if (wp_script_is(‘jquery’, ‘done’))

    This fails when using a minifier such as BWP. Perhaps an option in setup to override the test and force inclusion when we know jQuery will be loaded.

    I have problems with BWP minify and this slider either, and I realized that problem not in css or js-files, but in js-code. Slider could not put code like this on page:

    	jQuery(document).ready(function() {
    		jQuery('#sample_slider').owlCarousel({
    			itemsCustom : [
    				[0,1],
    				[480,2],
    				[768,3],
    				[980,4],
    				[1200,4],
    				[1400,4]
    			],
    			autoPlay : 4000,
    			paginationSpeed : 300,
    			slideSpeed : 300,
    			rewindSpeed : 1000,
    			rewindNav : true,
    			stopOnHover : true,
    			navigation : true,
    			navigationText : ['',''],
    			pagination : true,
    			itemsScaleUp : false,
    			mouseDrag : true,
    			touchDrag : true
    		});
    	});

    That code.
    When I put it by myself in footer.php slider starts working.
    But I am not sure it is a right solution)

    • This reply was modified 8 years, 3 months ago by anna007.

    Anna, so that’s exactly what I was seeing and it has to do with the check for jQuery.
    You can manually put the code in, but then if you change settings, it won’t automatically update.

    In the meantime, if you want to keep everything the same, you can edit the php code and make one small change. (Note: if there is a plugin update and Simon hasn’t fixed this, you’d have to make the change again and during that time your sliders would not be working.)

    Find: slide-anything-frontend.php in
    /wp-content/plugins/slide-anything/php

    Open it in a text editor and near the bottom find this line:
    if (wp_script_is(‘jquery’, ‘done’))

    replace it with:

    //  if (wp_script_is(‘jquery’, ‘done’))
        if (1)

    This will force the output of the script code without verifying that jQuery is present.

    Hopefully Simon can add in an override in the settings to handle this as I was not able to find a way to detect a minifier and make sure that jQuery was loaded.

    Hi, patmills!
    Thank you very much for your detailed explanation.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘W3 Total Cache breaks Slide Anything…?’ is closed to new replies.