Download
													Demo
								
					
				
					
							
		- Overview
 - Documents
 
						User Rating:  0/5 ( 0 votes) 
						
					Your Rating: 
					Saucy Slider is a cool jQuery plugin for creating a responsive content slider with CSS3 based smooth horizontal parallax effects. Comes with lots of options to customize the parallax effects using HTML data-* attributes and javaScript properties.
Source: jqueryscript.net
1. INCLUDE JS FILES
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script> <script src="saucySlider.js"></script>
2. HTML
Scenes and layers
<div id="stage"> <-- First Scene -- > <div data-scene="0" data-layer="1"></div> <-- Second Scene -- > <div data-scene="1" data-layer="2"></div> <-- Third Scene -- > <img src="img/photo.png" data-scene="2" data-layer="0"> </div>
- Stage: The root element that wraps all the pieces.
 - Piece: Any element inside the stage that is apart of the parallax animation.
 - Scene: A user defined point on the stage where pieces are centered around.
 - Layer: A piece's layer value affects its parallax speed.
 
Add nav buttons and/or pagers.
<-- Nav Buttons -- > <button class="next">Foward</button> <button class="prev">Back</button> <-- Pagers -- > <ul class="pagers"> <li>Scene One</li> <li>Scene Two</li> <li>Scene Three</li> </ul>
Background positions can be set to parallax.
<div data-bg-x="1" data-bg-y="1">
Pieces can be nested inside one another and move relative to their parents.
<div data-scene="4" data-layer="0">
  <div data-inner data-layer="2">
    I am nested inside another piece!
  </div>
</div>
4. OPTIONS
scenePoints     : [],   // Whole number pixel value where each scene starts
sceneTimes      : [],   // Miliseconds of transition time between each scene
sceneNames      : [],   // The name of each scene to appear in the URL hash
pager           : false,// jQuery object of all pager elements
nextButton      : false,// jQuery object of the element that triggers the move to the next scene
prevButton      : false,// jQuery object of the element that triggers the move to the previous scene
sceneMoved      : function(a){},    // Callback function when a scene moves
sceneStopped    : function(a){},    // Callback function when a scene stops
sceneCanceled   : function(a){}     // Callback function when a scene is canceled
5. HTML data-* attributes
- data-scene: Designates which scene the element belongs to
 - data-layer: Designates the speed of the element's parallax effects
 - data-bg-x: Designates the speed of the element's parallax effects for its horizontal background position
 - data-bg-y: Designates the speed of the element's parallax effects for its vertical background position
 - data-transition: Used to add other CSS transition values without overriding SaucySlider's transitions
 
JS Tutorial
						
		