how to use Jsoup in site that has lazyload scrollL

2019-04-08 02:05发布

问题:

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?

here is 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>

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.

Thanks

回答1:

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