sSlider is a lightweight jQuery slider toolkit. View source code on github.
The package contain css styles, images and the minified version of sSlider
<head> ... <link rel="stylesheet" href="path/to/sSlider/css/jQuery.sSlider.min.css" /> <script src="http://code.jquery.com/jquery-1.10.2.min.js"></script> <script src="path/to/sSlider/jQuery.sSlider.min.js"></script> ... </head>
<body> ... <div id="mySlider" class="sSlider"> <div><img src="path/to/image/new-york.jpg" /><span>New York</span></div> <div><img src="path/to/image/paris.jpg" /></div> <div><img src="path/to/image/cars.jpg" /><span>My new car</span></div> <div><img src="path/to/image/landscape.jpg" /></div> </div> ... </body>
<script> $(document).ready(function(){ $('#mySlider').sSlider(); }); </script>
Option name | Default | Accepted values | Example |
'animationType' | 'fade' | 'fade' 'no-effect' 'slideH' 'slideV' 'random' |
$('#selector').sSlide({ 'animationType': 'slide' }) |
'autoslide' | true | true false |
$('#selector').sSlide({ 'autoslide': false }) |
'fixedSize' | false | false { 'width': 'XXXpx/%', 'height': 'YYYpx/%' } |
$('#selector').sSlide({ 'fixedSize': { 'width': '500px', 'height': '40%' } }) |
'nav' | true | true false |
$('#selector').sSlide({ 'nav': false }) |
'progressBar' | true | true false |
$('#selector').sSlide({ 'progressBar': false }) |
'responsive' | true | true false |
$('#selector').sSlide({ 'responsive': false }) |
'speed' | 7000 | int | $('#selector').sSlide({ 'speed': 12000 }) |
<script> $(document).ready(function(){ $('#selector').sSlide({ 'animationType': 'slideV', 'fixedSize': { 'width': '1000px', 'height': '400px' }, 'nav': false, 'speed': 4000 }); ... }); </script>