问题描述:

jQuery load more content when scroll to bottom of the page. My script is working well on Safari/iPad browser and android Mozilla browser. But not worked on Android default and Chrome browsers.

$("#div").scroll(function() {

if ($(this).scrollTop() >= ($(this)[0].scrollHeight - $(this).outerHeight())) {

// load more content function

}

});

网友答案:

Try this

$("#div").animate({scrollTop: $("#div")[0].scrollHeight}, 1000);
    $('#div').scroll(function() {
    //content goes here
     });
相关阅读:
Top