Endless scroll paging in jquery Safari
Posted
by
socheata
on Stack Overflow
See other posts from Stack Overflow
or by socheata
Published on 2012-06-29T03:43:29Z
Indexed on
2012/06/30
21:16 UTC
Read the original article
Hit count: 135
I'm using :
$(window).scroll(function () {
if ($(window).scrollTop() + 10 >= ($(document).height() - $(window).height())) {
loadContent();
}
}
It works fine with Chrome, IE, Firefox but except in Safari. In function loadContent
, I used JSON to load data, as this tutorial. But while I test in Safari, It takes the content twice from JSON. If the other takes 9 items, then Safari takes 18 items.
Does anyone know how to solve this problem? Thanks.
© Stack Overflow or respective owner