$(window).on("scroll",function(){ var sctop=$(window).scrollTop(); if ($(window).scrollTop() >= $(document).height() -$(window).height()){ alert("到底了") } })