• Resolved noober16

    (@noober16)


    Hello,

    I started building a new webpage and I want to a add a slider using slide anything.
    The slider isn′t displayed an the page, I read some threads and googled but can′t fix it.

    Link: https://johannes-sacht.de/home/

    The red line is the border of the div that surrounds the slider.

    Has anyone an idea?

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

Viewing 13 replies - 1 through 13 (of 13 total)
  • Hello,

    I think I have the same problem. I’ve checked the changelog and the reason the slides aren’t appearing is likely due to patch 2.1.19 which adds a feature that hides the slides until the javascript has been executed. However, for some reason the javascript isn’t executing.

    – I have no other plugins installed (apart from the default anti-spam plugin)
    – I have no javascript errors, warnings or messages in my console.
    – I have no failed network requests in my network tab.
    – I have tested this on the latest versions of Chrome, Firefox and Safari.
    – I am using WordPress version 5.0.1

    Is this a known issue? Is there a workaround or fix available?

    Plugin Author simonpedge

    (@simonpedge)

    Hi your problem is the CSS ID you have assigned to your SA Slider. It is not unique – see this screenshot:
    https://images.devs-on.net/Image/TGquBIfzBfpMWkm5-Region.png

    For each SA Slider, JavaScript creates an Owl Carousel instance targeting a specific CSS ID container, with each child div of that container representing a single slider.

    In your case the JavaScript looks for a container with a CSS ID “cv_slider”. It come across the paragraph preceding your slider with this ID and then attempts to build a slider from this container.

    So if you give your SA slider a different, unique CSS ID, this will resolve this issue.

    Thread Starter noober16

    (@noober16)

    @simonpedge
    Hi
    thanks for your help, but it doesn′t solve the problem – or more likely I did something wrong ??
    I changed the CSS ID but still the slider doesn′t show up.

    Hi. I’m having what sounds like the same issue.
    Changing the CSS ID’s doesn’t solve the problem for me either.
    Just downloaded and installed the plugin today.

    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 noober16

    (@noober16)

    Hi
    thanks for your support!

    activating another theme did the job, reactivating my theme makes the slider disapear again.

    Have you any idea where to start to look for in the theme to make the slider work. My theme is build on bases of a basic tutorial, so there is probably some essentaila stuff missing.
    This is my second website in WP so I am not very familiar with trouble shooting.

    Best
    Johannes

    • This reply was modified 6 years, 2 months ago by noober16.
    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.

    Thread Starter noober16

    (@noober16)

    I updated to version 2.1.20 but the slider still doesn′t show up… but I think the bug is in my page template.

    I’m experiencing the exact same problem.
    Changing the theme resolves the problem.

    I will look into the code of the theme, and hopefully find the difference between the working, and the one not working, and i will post it here.

    @simonpedge: Awesome plugin, and thank you for the very quick support!

    @noober16 @simonpedge
    I’ve solved the problem for my other theme, by adding the following to functions.php:

    function insert_jquery(){
    wp_enqueue_script(‘jquery’, false, array(), false, false);
    }
    add_filter(‘wp_enqueue_scripts’,’insert_jquery’,1);

    I googled (https://wordpress.stackexchange.com/questions/111563/how-to-load-the-wordpress-jquery-in-the-head-section) that some plugins only add jquery to the footer, and not header, and that code should enforce it being added to the header.

    Thank you for pointing me in the correct direction.

    Plugin Author simonpedge

    (@simonpedge)

    Thank you madsens for digging into this.

    This is cropping up a few times now. jQuery is an essential, required part of WordPress, but some themes are now choosing to load it within the theme footer, instead of the theme header. Plugins that generate shortcode output containing (dynamic) JavaScript dependent on jQuery will not work in these instances. It seems some themes are doing this for possible performance enhancements – the page loads first in its entirety before the JavaScript. But the problem occurs when the page content (plugins) is dependent on the JS in order to work.

    I’m surprised these themes do not have an option to ‘Turn Off’ this feature?
    Its not just my plugin that this will affect. These themes should advertise that this feature will cause compatibility issues with some plugins.

    Also many caching or optimisation plugins have an option to load all JS in the footer as a performance option – be careful with this.

    Thread Starter noober16

    (@noober16)

    Hello again,
    big cheers for your support guys!

    I inserted the code in the functions.php in wp-includes folder – leads to this message:

    Warning: Use of undefined constant ‘wp_enqueue_scripts’ – assumed ‘‘wp_enqueue_scripts’’ (this will throw an Error in a future version of PHP) in /www/htdocs/w00b9bb7/wp-includes/functions.php on line 80

    Warning: Use of undefined constant ’insert_jquery’ – assumed ‘’insert_jquery’’ (this will throw an Error in a future version of PHP) in /www/htdocs/w00b9bb7/wp-includes/functions.php on line 80

    any idea for this one? like mentioned above, I am a complete newbie to wp & php

    • This reply was modified 6 years, 2 months ago by noober16.
    Thread Starter noober16

    (@noober16)

    I just updated the slider plugin and now it displays as intended.

    Thanks again guys for your support and hard work!

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Slider isn′t displayed on page’ is closed to new replies.