//slowScroll function scroll() { $('html, body').animate({ scrollTop: $("#divName").offset().top }, 2000)}; window.onload = scroll;