JavaScript Snappy Page Scrolling
I'm trying to find a way to have a snappy and automated page scrolling.
I'd like to use jQuery or equivalent to get something like this:
http://www.dezinerfolio.com/wp-content/uploads/smoothscrolldemo/df_smooth_scroll.html
Additionally I'd like to have a snappy feeling to it.
When using the scrollb开发者_Go百科ar or mousewheel I'd like the site so snap to a defined section. Can this be somehow done?
Cheers,
L
I realize this post is not flagged with a jQuery tag, but to accomplish such scrolling with cross-browser compatibility, I highly suggest implementing jQuery and the jQuery scrollTo Plugin (DEMO).
To be 100% honest, I am not sure how you would accomplish the scrolling with the mousewheel/scroll bar, but the plugin provides a simple interface for smooth scrolling via links/object clicks.
You could start with something like
=> http://www.jsfiddle.net/steweb/P5q9X/ (jQuery)
or => http://www.jsfiddle.net/steweb/TzJhu/ (mootools)
I just came across a really cool jQuery plugin which is exactly what you want. jQuery Waypoints
精彩评论