doScroller - Single Page Scroller
Thank you for purchasing doScroller. If you have any questions that are beyond the scope of this help file, please feel free to email us. Thanks so much!
Thank you for purchasing doScroller. If you have any questions that are beyond the scope of this help file, please feel free to email us. Thanks so much!
You can switch page using API methods like next(), Prev(), go(), keyboard up/down arrow, deeplinking etc.
doScroller is compatible with different Responsive frameworks like Twitter Bootstrap, Foundation etc.
doScroller is compatible with HTML4 div based layouts and HTML5 markup like nav, section.
<div id="custom-navigation" class="default-theme">
<ul>
<li><a href="#">Link 1</a></li>
<li><a href="#">Link 2</a></li>
<li><a href="#">Link 3</a></li>
<li><a href="#">Link 4</a></li>
<li><a href="#">Link 5</a></li>
</ul>
</div>
<div id="container">
<div class="section"></div>
<div class="section"></div>
<div class="section"></div>
<div class="section"></div>
<div class="section"></div>
</div>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script> <script src="js/jquery.doscroller.js"></script> <script> jQuery(document).ready(function($){ $('#container').doScroller({ pageClass: 'section', nav: '#custom-navigation', scrollOffset: -50 //Adjust the destination point of each page with a positive or negative integer. }); }); </script>Basic Demo
<header class="navigation-container"></header> <section> <article>Home</article> </section> <section> <article>About us</article> </section> <section> <article>Features</article> </section> <section> <article>Services</article> </section> <section> <article>Contact us</article> </section> <footer> <article>Footer</article> </footer>
$('body').doScroller({ nav: ['Home', 'About us', 'Features', 'Services', 'Contact us'], HTML5Enabled: true, navPlaceHolder:'.navigation-container' //Class or Id where you want to add Navigation. navClass:'navbar', //Claas name of navigation. scrollOffset: -50 //Adjust the destination point of each page with a positive or negative integer. }); // Note: If HTML5 mode true then there is no need to specify "pageClass". It will consider "Section" tag as a page.HTML5 Demo
$('#container').doScroller({ deepLink:true }); //Please note that IE7 does not support history API so that deeplinking feature will works but we can't change page using back button and forward button of browser.Deeplinking Demo
$('#container').doScroller(); //Animates page to next section. doScroller.next(); //Animates page to previous section. doScroller.prev(); //Animates page to fifth section. doScroller.goTo(5); //pass integer value as per page number //Returns index value of the current section doScroller.current;API Demo
Variable | Default Value | Description |
---|---|---|
transitionSpeed | 500 | page transition speed, in ms |
easing | 'swing' | Easing function for extra transition effect. Read more about easing functions. |
pageClass | 'page' | Comman class name used to identify page sections. |
menuItemClass | 'menu-item' | Adds class to menuItem when navigation generated dynamicaly via Array. Note : this option will work only if navigation genrated via javascript Array. |
menuActiveClass | 'active' | Adds class to current menuItem. |
navClass | 'default-theme' | Adds class to Navigation container when navigation generated dynamicaly via Array. Note: this option will work only if navigation genrated via javascript Array. |
deepLink | false | Deep linking module makes URL automatically change when you switch pages and you can easily link to specific page. Note: Please note that IE7 does not support history API so that deeplinking feature will works but we can't change page using back button and forward button of browser. |
HTML5Enabled | false | Set true if you want to use HTML5 markups like, <section>, <nav> etc. |
keyboardNavEnabled | true | Navigate pages with keyboard up and down arrows. |
nav | [ ] | Accepts an array of navigation links name (string) or ClassName/ID where custom navigation added. |
navPlaceHolder | ' ' | Accepts an Id or ClassName where you want to add dynamicaly generated navigation via Array. Note: this option will work only if navigation genrated via javascript Array. |
scrollOffset | 0 | Adjust the destination point of each page with a positive or negative integer. |
initialize | function() { } | triggers after doScroller is initialized. |
beforeAnimStart | function() { } | triggers before page animation start. |
afterAnimComplete | function() { } | triggers after page animation completed. |
pageChange | function() { } | triggers when page changes via manual scroll or navigation click or API methods. |
Once again, thank you so much for purchasing doScroller. As I said at the beginning, I'd be glad to help you if you have any questions relating to this plugin. No guarantees, but I'll do my best to assist. If you have a more general question relating to the plugin on Codecanyon, please feel free to email us.