Created
September 13, 2013 06:14
-
-
Save sagarjadhav/6547210 to your computer and use it in GitHub Desktop.
jQuery smooth scroll animation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Smooth Scroll */ | |
jQuery('.rtp-back-to-top').click( function() { | |
jQuery('html, body').animate({ | |
scrollTop: jQuery( jQuery(this).attr('href') ).offset().top | |
}, 1000); | |
return false; | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment