function onScroll(event) {
// Only check when we're not still waiting for data.
if(!isLoading) {
// Check if we're within 100 pixels of the bottom edge of the browser window.
var closeToBottom = ($(window).scrollTop() + $(window).height() > $(document).height() - 100);
if(closeToBottom) {
loadData();
}
}
};
In document.read function, bind to scroll event by
$(document).bind('scroll', onScroll);
--
Best,
--
On Twitter ==> http://twitter.com/phpcamp
On Facebook ==> http://www.facebook.com/campersfanpage
You received this message because you are subscribed to the Google
Groups "phpcamp" group.
To post to this group, send email to php...@googlegroups.com