我想从此网页获取内容: https://play.google.com/store/apps/category/BUSINESS/collection/topselling_paid
只有向下滚动时才会显示较低的应用。我尝试了几种解决方案,例如: How to scroll down with Phantomjs to load dynamic content
Scroll down to bottom of infinite page with PhantomJS in Python
目前内容的工作解决方案(直接可用而不滚动)是:
var page = require('webpage').create();
var fs = require('fs');
page.open('https://play.google.com/store/apps/category/BUSINESS/collection/topselling_paid', function () {
page.evaluate(function(){
});
page.render('export.png');
fs.write('test.html', page.content, 'w');
phantom.exit();
});
包括page.scrollPosition
也无济于事。如何获取动态生成的内容?