function isScrolledIntoView(o,r){
o=$(o);
var t=$(window),
r=r||0,
e=t.scrollTop(),
i=e+t.height(),
n=o.offset().top+r,
f=n+o.height(),
h=n>i;
console.log(o.offset().top);
if(h)
return!1;
var l=f>e;
return l?!(h&&l):!1
}
浏览器报错Cannot read property 'top' of undefined
但我console.log就能输出这个值,请问是什么问题?
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
小伙看你根骨奇佳,潜力无限,来学PHP伐。