screen shot is not accurate as its seeing in browser
-
Which version of PhantomJS are you using? Tip: run
phantomjs --version. : version : 1.9.8 -
What steps will reproduce the problem? : I pasted my script in this issue.
-
Which operating system are you using? : Ubuntu 14
-
Did you use binary PhantomJS or did you compile it from source?
-
Please provide any additional information below.
My words:
With this below code i tried to capture screen from a url but it seems its not giving perfect screen shot.. Or i am doing something wrong ?
screen shot : http://www.awesomescreenshot.com/image/2275399/7cf995d2e287cb87c4ca4895b6b69934
Website : http://www.whiteboardexplainers.com/
var system = require("system");
if (system.args.length > 0) {
var page = require('webpage').create();
page.viewportSize = {width: 1280, height: 1024};
page.open(system.args[1], function() {
var pageTitle = system.args[1].replace(/http.*\/\//g, "").replace("www.", "").split("/")[0]
var filePath = "pageTitle + '.png';
window.setTimeout(function () {
page.evaluate(function() {
document.body.bgColor = 'white';
});
page.render(filePath);
console.log(filePath);
phantom.exit();
}, 200);
});
}
@nk-nareshkumar you need to set clipRect to take a screenshot of a subsection of the screen.
screen shot : http://www.awesomescreenshot.com/image/2275399/7cf995d2e287cb87c4ca4895b6b69934
Website : http://www.whiteboardexplainers.com/
In these both screen the only difference the header issue is coming in captured screenshot.. not getting why you suggested clipRect method,. correct me if i am wrong.
your right.
i see the following in phantomjs 2.1.1:

and on phantomjs 2.5.0-beta

so it looks like a phantomjs 1.9.8 issue.
ok.. thank you .. i will test after update the phantomjs package
Due to our very limited maintenance capacity, we need to prioritize our development focus on other tasks. Therefore, this issue will be automatically closed (see #15395 for more details). In the future, if we see the need to attend to this issue again, then it will be reopened. Thank you for your contribution!