Posted By

tucq88 on 01/23/14


Tagged

link jquery button top back


Versions (?)

Back to top button


 / Published in: PHP
 

Button that onclick with scroll to top of the page

  1. // Back To Top
  2. $('a.top').click(function(){
  3. $(document.body).animate({scrollTop : 0},800);
  4. return false;
  5. });
  6.  
  7. //Create an anchor tag
  8. <a class="top" href="#">Back to top</a>

Report this snippet  

You need to login to post a comment.