qingmingsang

            console.log(document.body.scrollHeight);
            var a = document.body.scrollHeight;
            window.addEventListener("scroll", function(event) {
                var scrollTop = document.documentElement.scrollTop || window.pageYOffset || document.body.scrollTop;
                console.log(scrollTop);
                if(scrollTop > (a/2)){
                    console.log(\'xxxxxxxxxxxxxxxxxxx\');
                    
                }
            });

分类:

技术点:

相关文章:

  • 2022-01-02
  • 2022-01-30
  • 2021-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-11-21
  • 2021-12-23
猜你喜欢
  • 2021-12-23
  • 2022-12-23
  • 2021-12-23
  • 2021-12-23
  • 2021-12-23
相关资源
相似解决方案