Please note, this is a STATIC archive of website www.themepunch.com from 28 Sep 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

API Example – Pause/Resume the slider on page scroll

This article is now outdated!

For version 5.0+, this can now be easily achieved with the “Stop Slider out of Viewport” option shown here.

This example shows how you can toggle the slider’s “play” state based on whether the slider is visible on the page or not.

 

 

If you already have some type of “window scroll” script, you can integrate parts of the example into your current script.  Otherwise, add the example script below to the slider’s Custom JavaScript section.

 

Before starting, it will be important to find your slider’s “API Name”.  You can find this in your slider’s API Section, in the slider’s main settings page. Once you get your slider’s “revapi” name, replace the “revapi1” part in the beginning of the script below.