Skip to content

Instantly share code, notes, and snippets.

@lyhcode
Created May 10, 2018 17:48
Show Gist options
  • Save lyhcode/248652059616b594cacfe37f9a6a6849 to your computer and use it in GitHub Desktop.
Save lyhcode/248652059616b594cacfe37f9a6a6849 to your computer and use it in GitHub Desktop.
var system = require('system');
var url = system.args[1];
var filename = system.args[2];
var page = new WebPage();
page.open(url, function (status) {
page.render(filename);
console.log(filename)
phantom.exit();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment