• Resolved ldelnay

    (@ldelnay)


    The shortcode puts the slider on the page but it is invisible. forcing it to appear makes all the sides appear and not rotate.

    The page I need help with: [log in to see the link]

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

    (@simonpedge)

    Try checking the ‘Use window.onload event’ checkbox (under ‘Other Settings). Also ensure ‘Enable Lazy Load images is disabled’.

    If you have no joy, then you will have to do the following:
    – Disable other plugins (one-by-one) to see if one of them is clashing with Slide Anything (re-enable theme after this test)
    – Activate another theme (e.g. TwentySeventeen theme) to see if the theme is causing the clash – reactivate your original theme after this test.

    Thread Starter ldelnay

    (@ldelnay)

    I have ‘Use window.onload event’ checked and “Enable Lazy Load images” unchecked. It doesn’t appear in the 2019 theme either (I’m using a custom theme built on underscores) but it does appear in 2015, 2016 and 2017 themes. Is there something recently added to 2019 and underscores that isn’t in the earlier themes that may be affecting this?

    Plugin Author simonpedge

    (@simonpedge)

    Well the big change that happened a week or so ago was the introduction of WordPress 5.0, with it’s new “Block Editor” – which is terrible in my (most people’s) opinion. Are you using the new Block Editor or using the Classic Editor – or using another page builder? There could be some teething problems with this new WP release…

    Thread Starter ldelnay

    (@ldelnay)

    Strange new development: I added a shortcode for another carousel plugin below the SA shortcode and both the SA slider and the new carousel slider appear. When I remove ONLY the carousel shortcode they BOTH disappear. I tried putting just a plain image below the SA shortcode and the SA slider was still invisible

    Thread Starter ldelnay

    (@ldelnay)

    I was using Guttenburg block editor. I switched back to classic but there was no change. Still invisible.

    Plugin Author simonpedge

    (@simonpedge)

    What happens when you disable the other Carousel plugin?
    I see that the other plugin also uses Owl Carousel – I’m thinking that this might be the clash.

    Thread Starter ldelnay

    (@ldelnay)

    The problem arose before the carousel plugin was even installed. In fact the SA is the only plugin I had installed when I encountered the issue. I think the Carousel plugin is calling Owl Carousel for the page and so when its present both work. Could SA not be correctly calling Owl Carousel?

    Plugin Author simonpedge

    (@simonpedge)

    I’ve no idea – am stumped – it makes no sense.
    1) Other sites I’ve got SA installed (e.g. edgewebpages.com) are on the latest version of WP etc, and they are fine, and
    2) You say you switched to the 2017 theme, and SA worked fine.

    Its almost as if jQuery is not initialising properly on the underscores/2019 theme – Owl Carousel required jQuery, but then why would that other Carousel plugin work?

    • This reply was modified 7 years, 5 months ago by simonpedge.
    Thread Starter ldelnay

    (@ldelnay)

    Same problem on a new blank page created with classic editor (http://prototype.d1mg.com/grpest/test/)

    Plugin Author simonpedge

    (@simonpedge)

    Ok, I think I know what the problem is. The JavaScript for the Slide Anything carousel is not being generated. I would guess that with these new WP 5 themes JQuery is now being loaded in the footer, and I load the JavaScript code in the body based on the following condition:
    if (wp_script_is('jquery', 'done')) { ...

    Could you possibly do me a favour. Could you edit the ‘/wp-content/plugins/slide-anything/slide-anything-frontend.php’ file and comment out the following 2 lines:
    LINE 461:
    if (wp_script_is(‘jquery’, ‘done’)) {
    CHANGE TO
    // if (wp_script_is(‘jquery’, ‘done’)) {

    Line 605:
    }
    CHANGE TO
    // }

    This would help me confirm that this is the issue. Otherwise if you could give me access to your site, I could look at making the changes…

    Plugin Author simonpedge

    (@simonpedge)

    Ok, please try upgrading to the latest version of Slide Anything, version 2.1.20. Hopefully this bug-fix resolves your issue.

    Plugin Author simonpedge

    (@simonpedge)

    Also it appears that your theme is loading jQuery in the footer, which is a bit dangerous. Slide Anything, as well as many other plugins require jQuery to be loaded in the header.

    Look at your theme options – is there a theme setting enabled, which forces jQuery to load in the footer?

    Thread Starter ldelnay

    (@ldelnay)

    I did the update which hasn’t seemed to solve the issue 🙁 I went to look in the slide-anything-frontend.php file but those lines of code are different- assuming that’s because of the update… maybe I shouldn’t have done that first. sorry. I don’t see any theme options even pertaining to the footer. though the slider does appear in the theme options preview. Is there a way to manually load jquery in the header? I know a little php, but I’m a graphic designer at heart and am mostly at home in css.

    Plugin Author simonpedge

    (@simonpedge)

    Ok, looking at your page again I see that there is a JavaScrupt error:
    Uncaught ReferenceError: jQuery is not defined
    (Press CTRL + SHIFT + J keys together to bring up the JavaScript console on most browsers)

    This is occurring because your Theme is loading jQuery in the theme footer, and Slide Anything requires jQuery to be loaded in the theme header. This may also be occurring because of an installed optimisation plugin which switches the jQuery to load in the theme footer in an attempt to speed up page load speeds.

    Many plugins that generate jQuery dynamically within shortcode output (such as Slide Anything) require that jQuery is loaded in the theme header.

    So check your theme options to see if there is an option to load jQuery in the theme footer (which is bad practice IMO as it will lead to plugin incompatibility issues) – if there is such an option, then un-check it. Also check to see if you have any optimisation/caching plugins installed with the option to load JavaScript/jQuery in the footer – this should also be disabled.

    Plugin Author simonpedge

    (@simonpedge)

    Been digging into this a bit further, and a Slide Anything user found a solution to this in another thread (thanks @madsens !)

    Try adding the following code to your ‘functions.php’ file:

    function insert_jquery(){
    wp_enqueue_script('jquery', false, array(), false, false);
    }
    add_filter('wp_enqueue_scripts','insert_jquery',1);
    • This reply was modified 7 years, 5 months ago by simonpedge.
    • This reply was modified 7 years, 5 months ago by simonpedge.
Viewing 15 replies - 1 through 15 (of 18 total)

The topic ‘Slider invisible’ is closed to new replies.