如何在具有lazyload scrollLoader.js的站点中使用Jsoup [英] how to use Jsoup in site that has lazyload scrollLoader.js

查看:160
本文介绍了如何在具有lazyload scrollLoader.js的站点中使用Jsoup的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个关于jsoup的问题,因为lazyload scrollLoader.js
我用java代码到达网站,我在jsoup.But上只列出了50个图像名称,当在网站上向下滚动时,大量图像不断加载。我的问题是,是否可以将图像数量发布到与 Jsoup.connect()一起使用的网址中以从网站获取所有图像?

I have a problem about jsoup because of lazyload scrollLoader.js I reach site with java code, i have listed only 50 image name by jsoup.But when scroll down on site ,lots of image loads continously. My question is that, is it possible to post image amount into url that uses with Jsoup.connect() to get all image from the site?

这里是网站: http://www.logowik.com

这是网站中脚本的使用:

And this is the usege of script in the site :

<script type="text/javascript">

            $(document).ready(function(e) {
                CalculateColumns();
                recordCount = 50;
                groupID = "0";
                catID = "0";
                query = "";
                userEntry = "";
                groupInterval = "0";
                AddEvent(window, "resize", CalculateColumns);
                document["scrollLoader"] = new scrollLoader({evn : getGrids, seize : 1});
                document["scrollLoader"].DoScroll();
                addLogoClickEvent();
            });


    </script>

我用url发布这些参数,如:
http:/ /www.logowik.com/index.php?g=1&groupID=1&catID=0
使用此网址我得到50张图片,因为 recordCount在脚本中= 50 。但我无法将此参数发布到网址。
要获得100张图片,我试试这个网址: http://www.logowik.com/index.php?recordCount=100&g=1&groupID=1&catID=0
但它没有效果。

I post this parameters with url like : http://www.logowik.com/index.php?g=1&groupID=1&catID=0 with this url I get 50 image,because of recordCount = 50 in script. but i cannot post this parameter to url. For getting 100 images, I try this url: http://www.logowik.com/index.php?recordCount=100&g=1&groupID=1&catID=0 but it doesn't effect.

谢谢

推荐答案

使用firebug或chrome dev工具网络面板查看加载图像时生成的所有请求,然后只需在jsoup中重新创建它们。

Use firebug or chrome dev tools network panel to see all the requests generated when loading the images, then just recreate them in jsoup.

这篇关于如何在具有lazyload scrollLoader.js的站点中使用Jsoup的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆