pandorafms/pandora_console/include/test.js

20 lines
637 B
JavaScript
Raw Normal View History

var webPage = require("webpage");
2018-05-28 17:47:40 +02:00
var page = webPage.create();
var url =
"http://nova/pandora_console/operation/agentes/stat_win.php?type=sparse&period=86400&id=136574&label=QXJ0aWNhJiN4MjA7d2ViJiN4MjA7cGFnZSYjeDIwO2V4YW1wbGU%3D&refresh=600&draw_events=0";
2018-05-28 17:47:40 +02:00
var r = page.addCookie({
name: "PHPSESSID" /* required property */,
value: "23qu7l1sgb3iq3bkaedr724hp3" /* required property */,
path: "/pandora_console",
domain: "nova"
2018-05-28 17:47:40 +02:00
});
console.log(r);
page.viewportSize = { width: 750, height: 350 };
page.open(url, function start(status) {
page.render("output.jpeg", { format: "jpeg", quality: "100" });
2018-05-28 17:47:40 +02:00
phantom.exit();
});