Web scraping 如何使用phantomjs在页面之间导航
我想在同一Web scraping 如何使用phantomjs在页面之间导航,web-scraping,phantomjs,Web Scraping,Phantomjs,我想在同一页面内的页面之间导航。只使用phantomjs打开(url,函数(状态){}。这可能吗 例如: page.open(url, function(status) { page.includeJs("https://code.jquery.com/jquery-3.0.0.slim.min.js", function() { var response = page.evaluate(function() { ..code..
页面内的页面之间导航。只使用phantomjs打开(url,函数(状态){}
。这可能吗
例如:
page.open(url, function(status) {
page.includeJs("https://code.jquery.com/jquery-3.0.0.slim.min.js", function() {
var response = page.evaluate(function() {
..code..
window.location.replace('new url');
..code for new url..
return response;
});
console.log(response);
phantom.exit();
});
});
非常感谢您的帮助。我想最好的方法就是使用casperjs