For support please checkout http://themepunch.ticksy.com !
This chapter will gives you general instructions on how to install the slider and setup the options. Later chapters will be more detailed if needed.
What files do I need to upload to my server?
Please upload the rs-plugin folder to your server. In this folder you will find the following subfolders containing all of the items content:
You could use your own jQuery but we recommend loading it directly from the Google ressources (see later in this documentation).
You will find many examples in your downloaded zip under the examples&sources folder..
Implement the jQuery
Add the following lines to your HTML Head:
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js>
Add Revolution js and css files to your HTML page
Also in the <HEAD> section:
<!-- jQuery REVOLUTION Slider -->
<script type="text/javascript" src="rs-plugin/js/jquery.themepunch.plugins.min.js"></script>
<script type="text/javascript" src="rs-plugin/js/jquery.themepunch.revolution.min.js"></script>
<!-- REVOLUTION BANNER CSS SETTINGS -->
<link rel="stylesheet" type="text/css" href="rs-plugin/css/settings.css" media="screen" />
This contains the JS and CSS for the Slider itself and some helping modules .
Create a Container for the Banner
Put it in the HTML: (the class names used here are only examples. In our Example files we called them banner-container, fullwidthbanner-container and fullscreenbanner-container, different then here below ! )
<div class="bannercontainer">
<div class="banner">...</div>
</div>
The Banner-container can have different Styling depending on that, which layout you wish to use.
Responsive Style
This Style allows you to creat predefined container sizes, undependent from sourrounding container, and create Medai Query (Browsr Size) Dependent responsive alterantives.
It requests
-
a container with predefined Width and Height Attributes,
-
Media Query dependent Sizing. - this should be always with the same proportion. Means Width/Height should always have the same result !!!
Put this in your CSS File (i.e) :
.bannercontainer {
padding:0px;
background-color:#fff;
width:960px;
position:relative;
position:relative;
margin-left:auto;
margin-right:auto;
}
.banner{
width:960px;
height:500px;
position:relative;
overflow:hidden;
}
@media only screen and (min-width: 768px) and (max-width: 959px) {
.banner, .bannercontainer { width:760px; height:395px;}
}
@media only screen and (min-width: 480px) and (max-width: 767px) {
.banner, .bannercontainer { width:480px; height:250px; }
}
@media only screen and (min-width: 0px) and (max-width: 479px) {
.banner, .bannercontainer { width:320px;height:166px; }
}
FullWidth Style
This Style allows you to have the banner always fit in the maximum width of the Sourrounding Container.
It requests:
-
a Fluid wrapping container (which will always change the size depending on browser size. I.e. width:100% etc..
Put this in your CSS File
.bannercontainer{
width:100% !important;
position:relative;
padding:0;
max-height:500px !important;
overflow:hidden;
}
FullScreen Style
This Style allows you to have a banner always fit in the maxium screensize. In Some option you can select containers which will reduce the height of the banner with the height of the container. See examples.
It requests:
-
a fullwidth and fullheight wrapping container
Put this in your CSS File
.bannercontainer {
width:100% !important;
position:relative;
padding:0;
height:100%;
}
Create Your First Slides
Create an Unordered list inside the banner container where each <li> element will correspond to one slide.
<ul>
<!-- THE BOXSLIDE EFFECT EXAMPLES WITH LINK ON THE MAIN SLIDE EXAMPLE -->
<li data-transition="boxslide" data-slotamount="7" data-link="http://www.google.de">
<img src="images/slides/image1.jpg">
<div class="caption sft big_white" data-x="400" data-y="100" data-speed="700" data-start="1700" data-easing="easeOutBack">KICKSTART YOUR WEBSITE</div>
<div class="caption sfb big_orange" data-x="400" data-y="142" data-speed="500" data-start="1900" data-easing="easeOutBack">WITH SLIDER REVOLUTION!</div>
<div class="caption lfr medium_grey" data-x="510" data-y="210" data-speed="300" data-start="2000">UNLIMITED TRANSITIONS</div>
</li>
...
</ul>
Call the jQuery Plugin to build the Slider (Options need to be set of course...)
<script type="text/javascript">
var tpj=jQuery;
tpj.noConflict();
tpj(document).ready(function() {
if (tpj.fn.cssOriginal!=undefined)
tpj.fn.css = tpj.fn.cssOriginal;
tpj('.fullscreenbanner').revolution({
delay:9000,
startwidth:960,
startheight:500,
onHoverStop:"on",
thumbWidth:100,
thumbHeight:50,
thumbAmount:3,
hideThumbs:0,
navigationType:"bullet",
navigationArrows:"solo",
navigationStyle:"round",
navigationHAlign:"left",
navigationVAlign:"bottom",
navigationHOffset:30,
navigationVOffset:30,
soloArrowLeftHalign:"left",
soloArrowLeftValign:"center",
soloArrowLeftHOffset:20,
soloArrowLeftVOffset:0,
soloArrowRightHalign:"right",
soloArrowRightValign:"center",
soloArrowRightHOffset:20,
soloArrowRightVOffset:0,
touchenabled:"on",
stopAtSlide:-1,
stopAfterLoops:-1,
hideCaptionAtLimit:0,
hideAllCaptionAtLilmit:0,
hideSliderAtLimit:0,
fullWidth:"off",
fullScreen:"off",
fullScreenOffsetContainer:"#topheader-to-offset",
shadow:0
});
});
</script>
The Options to Initialise the Plugin (Theme Sorted):
Global Settings:
-
delay
The time one slide stays on the screen in Milliseconds. Global Setting. You can set per Slide extra local delay time via the data-delay in the <li> element (Default: 9000)
-
startheight
This Height of the Grid where the Captions are displayed in Pixel. This Height is the Max height of Slider in Fullwidth Layout and in Responsive Layout. In Fullscreen Layout the Gird will be centered Vertically in case the Slider is higher then this value.
-
startwidth
This Height of the Grid where the Captions are displayed in Pixel. This Width is the Max Width of Slider in Responsive Layout. In Fullscreen and in FullWidth Layout the Gird will be centered Horizontally in case the Slider is wider then this value.
Navigation Settings:
-
onHoverStop
Possible Values: "on", "off" - Stop the Timer if mouse is hovering the Slider. Caption animations are not stopped !! They will just play to the end.
-
thumbWidth / thumbHeight
The width and height of the thumbs in pixel. Thumbs are not responsive from basic. For Responsive Thumbs you will need to create media qury based thumb sizes.
-
thumbAmount
The Amount of visible Thumbs in the same time. The rest of the thumbs are only visible on hover, or at slide change.
-
hideThumbs
0 - Never hide Thumbs. 1000- 100000 (ms) hide thumbs and navigation arrows, bullets after the predefined ms (1000ms == 1 sec, 1500 == 1,5 sec etc..)
-
navigationType Display type of the navigation bar (Default:"none")
Possible values are: "bullet", "thumb", "none"
-
navigationArrows Display position of the Navigation Arrows (Default: "nexttobullets")
Possible values are "nexttobullets", "solo"
nexttobullets - arrows added next to the bullets left and right
solo - arrows can be independent positioned, see further options
-
navigationStyle Look of the navigation bullets if navigationType "bullet" selected.
Possible values: "round", "square", "round-old", "square-old", "navbar-old"
-
navigationHAlign, navigationVAlign
Vertical and Horizontal Align of the Navigation bullets / thumbs (depending on which Style has been selected). Possible values navigationHAlign: "left","center","right" and naigationVAlign: "top","center","bottom"
-
navigationHOffset navigationVOffset
The Offset position of the navigation depending on the aligned position. from -1000 to +1000 any value in px. i.e. -30
-
soloArrowLeftHaling, soloArrowRightHalign, solorArrowLeftHalign, soloArrowRightHalign
Vertical and Horizontal Align of the Navigation Arrows (left and right independent!) Possible values navigationHAlign: "left","center","right" and naigationVAlign: "top","center","bottom"
-
soloArrowLeftHOffset, soloArrowLeftVOffset, soloArrowRightHVOffset, soloArrowRightVOffset
The Offset position of the navigation depending on the aligned position. from -1000 to +1000 any value in px. i.e. -30 Each Arrow independent
-
touchenabled Enable Swipe Function on touch devices (Default: "on")
Possible values: "on", "off"
Loops
-
stopAtSlide
Stop Timer if Slide "x" has been Reached. If stopAfterLoops set to 0, then it stops already in the first Loop at slide X which defined. -1 means do not stop at any slide. stopAfterLoops has no sinn in this case.
-
stopAfterLoops
Stop Timer if All slides has been played "x" times. IT will stop at THe slide which is defined via stopAtSlide:x, if set to -1 slide never stop automatic
Mobile Visibility
-
hideCaptionAtLimit
It Defines if a caption should be shown under a Screen Resolution ( Basod on The Width of Browser)
-
hideAllCaptionAtLimit
Hide all The Captions if Width of Browser is less then this value
-
hideSliderAtLimit
Hide the whole slider, and stop also functions if Width of Browser is less than this value
Layout Styles
-
fullWidth
Possible Values: "on", "off" - defines if the fullwidth mode is activated
-
fullScreen
Possible Values: "on", "off" - defines if the fullscreen mode is activated
-
fullScreenOffsetContainer
The value is a Container ID or Class i.e. "#topheader" - The Height of Fullheight will be increased with this Container height !
-
shadow
Possible values: 0,1,2,3 (0 == no Shadow, 1,2,3 - Different Shadow Types)
-
videoJsPath
The Path to the VideoJs Files which are basically always under the rs-plugin/videojs/ folder. Default setting: videoJsPath:"rs-plugin/videojs/"
Slide Options
<li> - Every list item represents a new Slide. To Define Transitions, main links, etc. use the following data- values per list item.
Transition Effects
-
data-transition
The appearance transition of this slide. You can define more than one, so in each loop the next slide transition type will be shown.
Basic Transitions:
boxslide,boxfade
slotzoom-horizontal, slotzoom-vertical
slotslide-horizontal, slotslide-vertical
slotfade-horizontal, slotfade-vertical
curtain-1, curtain-2, curtain-3
slideleft, slideright, slideup ,slidedown
slidehorizontal, slidevertical
fade
random
Premium Transitions:
papercut
flyin
turnoff
cube
3dcurtain-vertical
3dcurtain-horizontal
premium-random
-
data-slotamount
The number of slots or boxes the slide is divided into. If you use boxfade, over 7 slots can be juggy.
-
data-masterspeed
The speed of the transition in "ms". default value is 300 (0.3 sec)
-
data-delay
A new Dealy value for the Slide. If no delay defined per slide, the dealy defined via Options will be used
Links (Full Slide Links)
-
data-link
A link on the whole slide pic
-
data-target
The target of the Link for the whole slide pic. (i.e. "_blank", "_self")
-
data-slideindex
Possible values: next,back, 1-x (where x is the max. Amount of slide) If this value is set, click on slide will call the next / previous, or n th Slide.
Thumbnail
-
data-thumb
An Alternative Source for thumbs. If not defined a copy of the background image will be used in resized form
The Main Image
Each Slide (<li> </li>) MUST include a main image which is added as a simple <img> tag at the first level. It can be a Simpe image, a colored or transparent image, or dummy image as lazy load version.
Simple Image
<img src="images/slides/slide13.jpg" >
Colored Background Instead of Image
<img src="images/slides/transparent.png" style="background-color:#56e34a" >
Lazy Loaded Image
<img src="images/slides/dummy.jpg" data-lazyload="images/slides/slide13.jpg">
The Captions / Layers
Each <li> (slide) can include unlimited amount of Captions. Caption are simple html markups with iframe, image, heading , paragraph and any other tags. Each Caption must be wrapped via a <div class="caption"></div>.
Each Caption has some special classes and some data- attributes, to set animation type, position, speed, easings etc.
Caption Classes
-
the "caption" class
It is the Wrapping main Class which is a MUST. Each Caption need to be defined like this, other way the Slider Plugin can not identifikate the Caption container
-
Styleing Captions (like "big_white", "big_orange", "medium_grey" etc...)
These are Styling classes created in the settings.css You can add unlimited amount of Styles in your own css file, to style your captions at the top level already
-
Animation Classes
Animation Classes defined the start / end animations on Captions.
Incoming Animation Classes:
sft - Short from Top
sfb - Short from Bottom
sfr - Short from Right
sfl - Short from Left
lft - Long from Top
lfb - Long from Bottom
lfr - Long from Right
lfl - Long from Left
fade - fading
randomrotate- Fade in, Rotate from a Random position and Degree
Outgoing Animation Classes:
stt - Short to Top
stb - Short to Bottom
str - Short to Right
stl - Short to Left
ltt - Long to Top
ltb - Long to Bottom
ltr - Long to Right
ltl - Long to Left
fadeout - fading
randomrotateout- Fade in, Rotate from a Random position and Degree
Caption data- settings
-
data-x
Possible Values are "left", "center", "right", or any Value between -2500 and 2500.
If left/center/right is set, the caption will be siple aligned to the position. Any other "number" will simple set the left position in px of tha caption.
At "left" the left side of the caption is aligned to the left side of the slider.
At "center" the center of caption is aligned to the center of slide.
At "right" the caption right side is aligned to the right side of the Slider.
-
data-y
Possible Values are "top", "center", "bottom", or any Value between -2500 and 2500.
If top/center/bottom is set, the caption will be siple aligned to the position. Any other "number" will simple set the top position in px of tha caption.
At "top" the top side of the caption is aligned to the top side of the slider.
At "center" the center of caption is aligned to the center of slide.
At "bottom" the caption bottom side is aligned to the bottom side of the Slider.
-
data-hoffset
Only works if data-x set to left/center/right. It will move the Caption with the defined "px" from the aligned position. i.e. data-x="center" data-hoffset="-100" will put the caption 100px left from the slide center horizontaly.
-
data-voffset
Only works if data-y set to top/center/bottom. It will move the Caption with the defined "px" from the aligned position. i.e. data-x="center" data-hoffset="-100" will put the caption 100px left from the slide center vertically.
-
data-speed
The speed in milliseconds of the transition to move the Caption in the Slide at the defined timepoint.
-
data-start
The timepoint in millisecond when/at the Caption should move in to the slide.
-
data-easing
The Easing Art how the caption is moved in to the slide (note! Animation art set via Classes !).
Possible Values are:
easeOutBack, easeInQuad, easeOutQuad, easeInOutQuad, easeInCubic, easeOutCubic
easeInOutCubic, easeInQuart, easeOutQuart, easeInOutQuart, easeInQuint
easeOutQuint, easeInOutQuint, easeInSine, easeOutSine, easeInOutSine
easeInExpo, easeOutExpo, easeInOutExpo, easeInCirc, easeOutCirc, easeInOutCirc
easeInElastic, easeOutElastic, easeInOutElastic, easeInBack, easeOutBack, easeInOutBack
easeInBounce, easeOutBounce, easeInOutBounce
-
data-endspeed
The speed in milliseconds of the transition to move the Caption out from the Slide at the defined timepoint.
-
data-end
The timepoint in millisecond when/at the Caption should move out from the slide.
-
data-endeasing
The Easing Art how the caption is moved out from the slide (note! Animation art set via Classes !).
Possible Values are:
easeOutBack, easeInQuad, easeOutQuad, easeInOutQuad, easeInCubic, easeOutCubic
easeInOutCubic, easeInQuart, easeOutQuart, easeInOutQuart, easeInQuint
easeOutQuint, easeInOutQuint, easeInSine, easeOutSine, easeInOutSine
easeInExpo, easeOutExpo, easeInOutExpo, easeInCirc, easeOutCirc, easeInOutCirc
easeInElastic, easeOutElastic, easeInOutElastic, easeInBack, easeOutBack, easeInOutBack
easeInBounce, easeOutBounce, easeInOutBounce
Special Classes within the Caption container
-
tp-scrollbelowslider
If this class added to an element within the caption container, it will scroll the Body Position to under the current slider (used in Fullscreen slider only)
-
tp-resizeme
Add class tp-resizeme to the container inside the caption and every item within (included the same container) will be responsive resized. Only needed if more than one depth exist in the container !
-
frontcorner, backcorner, frontcornertop, backcornertop
This classes added without any content in a closed div i.e. <div class="frontcorner"></div> within the container. It will cut the left/right side of the caption background in 45° 1:1
Banner Timer
In order to use a banner timer, you will need to add the markup within the banner or fullwidthbanner divs.
The markup should look like :
Top Positioned Banner Timer:
<div class="tp-bannertimer"></div>
Bottom Positioned Banner Timer:
<div class="tp-bannertimer tp-bottom"></div>
To remove this timer just simple remove the markup from the container, and that is it.
Responsive Layout
Responsive means that the slider will adjust to every screen width.
To achieve that you have to set a bunch of mediaqueries that will adjust the whole slider when a certain window size is used, or you will need to use our fullwidth style version, to let the banner always resize itself.
The basic containers are build like this ( in none Fullwidth, but 4 Level Responsive Version):
.bannercontainer {
padding:5px;
background-color:#fff;
width:890px;
position:relative;
margin-left:auto;
margin-right:auto;
}
.banner{
width:890px; // MUST BE THE SAME AS IN THE OPTIONS startwidth
height:490px; // MUST BE THE SAME AS IN THE OPTIONS startheight
position:relative;
overflow:hidden;
}
The media queries that build the screen dependend container sizes:
@media only screen and (min-width: 768px) and (max-width: 959px) {
.banner, .bannercontainer{ width:750px; height:412px;}
.bannershadow {width:750px;}
}
@media only screen and (min-width: 480px) and (max-width: 767px) {
.banner, .bannercontainer{width:470px; height:258px;}
.bannershadow {width:470px;}
}
@media only screen and (min-width: 0px) and (max-width: 479px) {
.banner, .bannercontainer{width:300px;height:165px;}
.bannershadow {width:300px; margin-top:-5px;}
}
Calculate the Resopnsive sizes
Here we can give you a short calculating example. The Width of the Responsive container depending on you in the different browser views. the height can be calculated via a simple example:
new width / original width * original height. So in our Examplce (step 1.) 750 / 890 * 490 == 413px
FullWidth Layout
This slider can go fullwidth too. We have added an index-fullwidth.html example for you in the zip.
Please note the basic change in the markup.
The surrounding containers are (only example, can be called differently)
<div class="fullwidthbanner-container">
<div class="fullwidthbanner">...</div>
</div>
The CSS is not splitted with Media-Queries but has a basic 100% value for width:
.fullwidthbanner-container{
width:100% !important;
position:relative;
padding:0;
max-height:450px !important; // Same value as in OPTIONS the startheight parameter
overflow:hidden;
}
FullScreen Layout
You can use the Slider also in FullScreen mode. It will need to have the possiblity to use the full width of the screen, means do not wrap it in any boxed container. For Fullscreen simple use the following markups and styles:
The markup could look like:
<div class="fullscreen-container">
<div class="fullscreenbanner">
</div>
</div>
The Style has 100% width and height simple.
.fullscreen-container {
width:100% !important;
position:relative;
padding:0;
height:100%;
}
Dont forget to use the option fullScreen:"on" to use in the initialisation. If you wish to have an offset, which allows you to add i.e. a Menu over the fullscreen slider, just use the fullScreenOffsetContainer: option and set it to the container which wrapps the menu i.e
The slider offers a public API which you can use to control component inside the Slider from within your own scripts. To access this api, use the following code.
var tpj=jQuery;
tpj.noConflict();
tpj(document).ready(function() {
if (tpj.fn.cssOriginal!=undefined)
tpj.fn.css = tpj.fn.cssOriginal;
var api = tpj('.banner').revolution(
....
You can see in the example index-responsive-API.html how to use the different functions, and how to get the trigered Events.
Once this is done you may use any of the following functions:
-
api.revpause() - Stops the Timer and autoplay
-
api.revresume() - Starts the Timer and resume to autoplay
-
api.revprev() - Change to previous slide
-
api.revnext() - Change to next slide
-
api.revshowslide(n) - Change to the slide with index Nr. (n)
-
api.revmaxslide() - Show the amount of slides
-
api.revscroll() - Scrollt Body under the Slide in FullScreen mode
Or you may use any of the following Events:
-
revolution.slide.onchange - Event is triggered when Slide has been rotated. data value will give you the current slide. i.e.
api.bind("revolution.slide.onchange",function (e,data) {
jQuery('#callbackinfo').html('Last Event: Slide Changed to '+data.slideIndex);
});
-
revolution.slide.onpause - Event is triggered when Slider is on Pause
-
revolution.slide.onresume - Event is triggered when Slider is back from Pause
-
revolution.slide.onvideoplay - Event is triggered when YouTube or Vimeo Video has been started (only Online Mode !)
-
revolution.slide.onvideostop - Event is triggered when YouTube or Vimeo Video has been stopped or Slide has been rotated (only Online Mode !)
-
revolution.slide.onstop - - Event is triggered when slider has been stopped due the Loop and stop at Slide parameters
-
revolution.slide.onbeforeswap - - Event is triggered when slider is going to change to next slide
-
revolution.slide.onafterswap - - Event is triggered when slider has finnishded the change of the transition (full transition finnished)
-
revolution.slide.onloaded - - Event is triggered when slider is loaded and it is prepared
Used Assets
-
jQuery Transit - CSS3 transitions and transformations
Copyright(c) 2011 Rico Sta. Cruz <rico@ricostacruz.com>
MIT Licensed.
-
jQuery WaitForImages 1.4
https://github.com/alexanderdickson/waitForImages
Licensed under the MIT licenses.
-
Template demo images licensed from Fotolia for preview usage. Please do not attempt to rip the images from the preview!
If you face problems with the installation or customization of our product please do not hesitate to contact us via our support ticket system:
http://themepunch.ticksy.com