jQuery Scroll to Top of Page on button click

$("#button").click(function(){
   $('html, body').animate({scrollTop: '0px'}, 300);
});
Note: 300 is given to slow down the scroll effect

Comments

Popular posts from this blog

SQL Interview Questions and Answers

Generic Interface and Factory Pattern in C#

How to get device info IMEI programmatically in xamarin android