Access our premium support and let us know your problems, we will help you solve them.

0
No products in the cart.

Forum Replies Created

Viewing 1 post (of 1 total)
  • Author
    Posts
  • in reply to: Scroll to an element with jQuery #9751
    blankuser669677
    Participant
    $('html, body').animate({scrollTop: 
      Math.min( 
        $(to).offset().top-margintop, //margintop is the margin above the target
        $('body')[0].scrollHeight-$('body').height()) //if the target is at the bottom
    }, 2000);
    
Viewing 1 post (of 1 total)