var totalheight = 0;
$(function(){
$(window).bind("scroll", function(){
totalheight = $(window).height() +$(window).scrollTop(); //浏览器的高度加上滚动条的高度
if (($(document).height()*9/10 <= totalheight)) { //当文档的高度小于或者等于总的高度的时候,开始动态加载数据
//加载数据
//
}
});
});