$(document).ready(function() { $("#scroll").click(function() { $('html, body').animate({ scrollTop: $("#commentlist").offset().top }, 1000); });});