I am using my linux box to try and periodically download my local skateboard park’s webpage and search for whether there are free skate-school lessons available.

I’m currently falling at the first hurdle as I am only getting a partially rendered . The crucial dynamic content is missing.

I’m using a bash command to get an html file:

$  get_page.js [my local skateboard park's URL] > [a_file.html]

My save_page.js looks like this:

var system = require('system');
var page = require('webpage').create();

page.open(system.args[1], function()
{
    setTimeout(function(){
    console.log(page.content);
    phantom.exit();
}, 10000);
});

There is a ten second in there – but it also fails to load the whole page with a 3 or 5 second .



Source link https://sqa.stackexchange.com/questions/29003/phantomjs-not--all-of-page-even-with-a-few--delay

LEAVE A REPLY

Please enter your comment!
Please enter your name here