So you know how on Facebo开发者_JAVA百科ok, if you start scrolling down through your news feed, you can see the DOM actually update on the fly based on how far you have scrolled down so it knows to go and retrieve/display new elements? I'm assuming it does this because they don't want to load the insane amount of records for each user every-time they load up their main page.
Looks like they load enough to fill maybe 2 visible screens or something at first, and then as you scroll down they double that, and then it comes to a point where they won't load any more and it asks you to load more.
How would I accomplish something like this? Would this be done in Javascript?
The search-term you are looking for is "Infinite Scroll". There's lots of ways to achieve this, including a jQuery plugin. As jQuery is built-in to ASP.NET I would recommend that.
精彩评论