jQuery simple slide to top animation

How to scroll to the top of the page using a jQuery Very simple code that you can add to your main.js file listening for a click event on $(‘a.top-page’), a link at the foot of the page. // Footer ‘Top of the page’ // gives a clean / simple animated slide to the page top $(‘a.top-page’).click(function(e) { e.preventDefault(); $(‘html, body’).animate(…read more →