-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Methods
goToSlide
Performs a slide transition to the supplied slide index (zero-based)
example:
slider = $('.bxslider').bxSlider();
slider.goToSlide(3);
goToNextSlide
Performs a "Next" slide transition
example:
slider = $('.bxslider').bxSlider();
slider.goToNextSlide();
goToPrevSlide
Performs a "Prev" slide transition
example:
slider = $('.bxslider').bxSlider();
slider.goToPrevSlide();
startAuto
Starts the auto show. Provide an argument false
to prevent the auto controls from being updated.
example:
slider = $('.bxslider').bxSlider();
slider.startAuto();
stopAuto
Stops the auto show. Provide an argument false
to prevent the auto controls from being updated.
example:
slider = $('.bxslider').bxSlider();
slider.stopAuto();
getCurrentSlide
Returns the current active slide
example:
slider = $('.bxslider').bxSlider();
var current = slider.getCurrentSlide();
getSlideCount
Returns the total number of slides in the slider
example:
slider = $('.bxslider').bxSlider();
var slideQty = slider.getSlideCount();
redrawSlider
Redraw the slider. Useful when needing to redraw a hidden slider after it is unhidden.
example:
slider = $('.bxslider').bxSlider();
slider.redrawSlider();
reloadSlider
Reload the slider. Useful when adding slides on the fly. Accepts an optional settings object.
example:
slider = $('.bxslider').bxSlider();
slider.reloadSlider();
destroySlider
Destroy the slider. This reverts all slider elements back to their original state (before calling the slider).
example:
slider = $('.bxslider').bxSlider();
slider.destroySlider();