how to change slider speed?

Asked on September 17, 2015 in Customization.

Please can you give an example of the jquery used to change the slider speed? The examples on http://www.idangero.us/ are all about setting up a new slider, not changing parameters for an existing slider.

DaveBear Layers User

No it doesn’t work perfectly. Bizarrely, it works for once round the slides, but then goes back to being super fast and annoying. Then, if you click a slide, it returns to the slower speed and stays there.

Is there an easy way to change the slider speed, that works properly?

on September 17, 2015.
Reply
  • Possible Answers to Your Question:

  • 2 Answer(s)
    Answered on September 17, 2015.

    To make it work I duplicated the jQuery code from after the slider markup, added it to my own custom js file and changed the parameters as necessary:

    Found this:

    
    var widget_layers_widget_slide_3_slider = $('#layers-widget-slide-3').swiper({
    
    //Your options here:
    
    mode: 'horizontal',
    
    pagination: '.widget-layers-widget-slide-3-pages',
    
    paginationClickable: true,
    
    watchActiveIndex: true,
    
    loop: true,
    
    autoplay: 4000
    
    });
    
    

    Added it to my custom.js file inside the docready, with the speed parameter added:

    
    var widget_layers_widget_slide_3_slider = $('#layers-widget-slide-3').swiper({
    
    //Your options here:
    
    mode: 'horizontal',
    
    pagination: '.widget-layers-widget-slide-3-pages',
    
    paginationClickable: true,
    
    watchActiveIndex: true,
    
    loop: true,
    
    autoplay: 4000,
    
    speed:1000
    
    });
    
    

    Works perfectly

    Which type of sample you will provide in the first chat. I need an Artwork sample for AssignmentHolic . Make sure to provide the sample which impresses me and I will hire you for this work.

    on November 26, 2020.
    Reply
    Answered on September 18, 2015.

    The following covers the swiper.js paramaters and how to implement them:
    http://www.idangero.us/swiper/api/

    They have a support forum here:
    http://www.idangero.us/swiper/forum/

    There are two speeds, the speed which is the actual animation, and autoplay, which is the interval in milliseconds between slide changes. Your speed is only 1 second compared to your auto-slide, which is 4 (typical speed for reading a few sentences is 5-10 seconds)

    Reply