Another Responsive Image Slider Plugin For jQuery - Download Another Responsive Image Slider Plugin For jQuery

Download Another Responsive Image Slider Plugin For jQuery

Posted on

This time I will share jQuery Plugin and tutorial about Another Responsive Image Slider Plugin For jQuery, hope it will help you in programming stack.

Another Responsive Image Slider Plugin For jQuery - Download Another Responsive Image Slider Plugin For jQuery
File Size: 634 KB
Views Total: 2631
Last Update:
Publish Date:
Official Website: Go to website
License: MIT
   

Yet another jQuery plugin for creating a responsive & cross-browser image slider that loops through a group of images with multiple effects and configuration options.

How to use it:

1. Include the required jQuery library and the jQuery slider plugin’s files in the page.

2 <script src="src/slider.js"></script>
3 <link href="src/slider.css" rel="stylesheet" type="text/css">

2. The Html to create an image slider with controls following the markup structure like this:

01 <div class="slider" slider>
02 <div class="slider-content">
03 <div><img src="1.jpg" alt="Picture 1"></div>
04 <div><img src="2.jpg" alt="Picture 2"></div>
05 <div><img src="3.jpg" alt="Picture 3"></div>
06 </div>
07 <div class="slider-nav">
08 <div class="slider-active"></div>
09 <div></div>
10 <div></div>
11 </div>
12 <div class="slider-prev slider-disabled">&lsaquo;</div>
13 <div class="slider-next">&rsaquo;</div>
14 </div>

3. Call the plugin with all the default settings.

1 $(document).ready(function() {
2   $(".slider").slider();
3 });

4. Options and defaults.

01 $(".slider").slider({
02   activeClass: 'slider-active', // for slide nav
03   autoPlay: true,
04   contentClass: 'slider-content',
05   disableClass: 'slider-disabled', // for slide 'prev btn' and 'next btn'
06   duration: 5000,
07   effect: 'fade',
08   easing: 'swing', // support 'swing' and 'linear', powered by jquery
09   navClass: 'slider-nav',
10   nextClass: 'slider-next',
11   prevClass: 'slider-prev',
12   speed: 1000,
13   trigger: 'click' // for slide nav
14 });

5. API methods.

01 // start the slider
02 $(".slider").slider('start');
03  
04 // stop the slider
05 $(".slider").slider('stop');
06  
07 // enable the slider
08 $(".slider").slider('enable');
09  
10 // disable the slider
11 $(".slider").slider('disable');
12  
13 // destroy the slider
14 $(".slider").slider('destroy');

Change log:

v0.1.1 (2016-05-27)

  • Added a new method: destroy.
  • Renamed the autoplay option to autoPlay.
  • Rename scrollx to scrollX
  • Rename scrolly to scrollY
  • Improved the cycle of the fade effect.
  • Stop sliding when mouse over the slider container.
  • Optimized the code style.

v0.0.2 (2014-08-09)


This awesome jQuery plugin is developed by fengyuanchen. For more Advanced Usages, please check the demo page or visit the official website.

source : jqueryscript.net