此Html代码
<div id="scroll-down">
<i class="fa fa-angle-double-down fa-5x wow bounceIn" data-wow-delay="2s"></i>
</div>
<div id="scroll-up">
<i class="fa fa-arrow-circle-o-up fa-2x" aria- hidden="true"></i>
</div>
&#13;
为什么当我点击Scroll-Up&amp;向下滚动按钮页面滚动停止
这个jQuery代码:
$(window).scroll(function () {
$('#scroll-down').click(function(){
$('html,body').animate({scrollTop : '632'},800);
});
var scrollUp=$('#scroll-up');
if(st>=1000) {
scrollUp.fadeIn(600);
}else{
scrollUp.fadeOut(600);
}
scrollUp.click(function(){
$('html,body').animate({scrollTop : '0'},800);
});
});
&#13;