Treehouse: Grow your CSS skills. Land your dream job.

Scroll to top slider

  • # April 30, 2010 at 5:02 pm

    Hi all,

    I got stuck at the moment with a scroll to top slider, It slides fine but when i click the scroll to top div it’s stay on top and i can’t scrll down

    can someone help me out?


    var amorzScroll = null;

    $(window).scroll(function () {
    var scrollTop = $(document).scrollTop();
    scrollTop = parseInt(scrollTop);

    var offset = amorzScroll+scrollTop+”px”;

    function (e) {
    $(‘html, body’).animate({scrollTop: ‘0px’}, 800);

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.