1.向上滾動 $(this).animate({ scrollTop: "-=50" }, 1000); 2.向下滾動 $(this).animate({ scrollTop: "+=50" }, 1000); 參數解讀:$(this)表示要實現上下滾動的對象,-50表示向上滾動50px , +50表示向下滾動50px ,1000表示滾動速度
1.向上滾動 $(this).animate({ scrollTop: "-=50" }, 1000); 2.向下滾動 $(this).animate({ scrollTop: "+=50" }, 1000); 參數解讀:$(this)表示要實現上下滾動的對象,-50表示向上滾動50px , +50表示向下滾動50px ,1000表示滾動速度
本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。