Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hello, I'd like to ask if it is possible to return to the first slide when the mouse isn't hovering the slideshow.
I have turned off the automatic cycle and created a pager. So now I can navigate through the Slideshow by hovering over the pager items. But I want the slideshow to return to the first slide when I am pointing at none of the items.
Thanks for any help
Comments
Comment #1
yvesvanlaer CreditAttribution: yvesvanlaer commentedHey ksaen
I came across the same problem: if my mouse is not on the slideshow container, I wanted to show the first slide.
I solved this with jQuery:
$("#your-slideshow-container-div").mouseout(function() {
Drupal.viewsSlideshow.action({ "action": 'goToSlide', "slideshowID": 'carousel_content_type-block', "slideNum": 0 });
});
Hope this helps someone.
If there is a easier way, please tell me.
Comment #2
NickDickinsonWildeThat's an ideal method of solving that. Don't want to add it to the module (adding everything can cause bloat) but good little snippet to add to your page.