Suppose I have a list of 500 thumbnails followed by the title. How do I load the images as the user scrolls down? (JQuery)

霸气de小男生 提交于 2019-12-24 13:01:41

问题


In mobile, the internet is slow. If I have a list of 500 images, this is going to take forever to load. I'd like to load the title of the image in a list, but as the user scrolls down, I want to start loading/downloading the <img> tag. How do I use Javascript/Jquery to do this?


回答1:


Try taking a look at this jQuery plugin:

Lazy Loading




回答2:


The Lazy Load Plugin for jQuery should do what you need to do. http://www.appelsiini.net/projects/lazyload




回答3:


Now, see Make images load when they enter visible section of browser?; apparently lazyload itself no longer works or is no longer available, but this gives other substitutes.



来源:https://stackoverflow.com/questions/2375703/suppose-i-have-a-list-of-500-thumbnails-followed-by-the-title-how-do-i-load-the

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!