I'm trying to lazy load (which is when you wait until someone scrolls into view of an item to load it) an entire web page, not just images. It is a similar format to the instagram home where you scroll and it loads as you scroll or the same with facebook and pinterest. I only want it in javascript though. I don't have any clue on how to do it (all other methods I found were extremely complicated and I couldn't implement them) but in conclusion a simple lazy load (another example is IFUNNY). Thanks!
Asked
Active
Viewed 457 times
0
-
2*I don't have any clue on how to do it* Unfortunately we expect some sort of input on SO. Show some code that you've tried, the HTML that you start with and the HTML that you want to load; give us something to work with. – Bram Vanroy Jun 30 '15 at 14:22
-
1I'm not sure that instagram is performing a lazy load the way to describe. IMO, they are just loading more images as you scroll, wich is more "infinite Scroll". This is done with a watcher on scroll position and an XHR query – aorfevre Jun 30 '15 at 14:26
-
check this out http://stackoverflow.com/questions/21963306/how-to-get-lazy-load-effect-to-full-page-in-html – Robin Jun 30 '15 at 14:29
1 Answers
3
- First listen to pagescroll
- Second get scrollbar position
- Third if scrollbar position >= 95% load data via Ajax

Community
- 1
- 1

schnawel007
- 3,982
- 3
- 19
- 27
-
-
Use [JQuery](https://jquery.com/) and use the Information of the Links. – schnawel007 Jun 30 '15 at 14:30
-