jquery跳转到固定class位置

<script type="text/javascript">

$("#nav_down").click(function(){
//var h = $(document).height()-$(window).height();
//$(document).scrollTop(h);
$('html, body').animate({
scrollTop: $(".content").offset().top
}, 2000);
})

//跳到头部

$("#nav_down").click(

function() {
  $('html,body').animate({
    scrollTop: 0
  }, options._speed);
});

</script>

原文地址:https://www.cnblogs.com/youxianyen/p/7065009.html