when i take screenshots using phanomjs using the following code works fine and I am getting width as 1920px and height is not a problem for me.
var webPage = require('webpage');
var page = webPage.create();
page.viewportSize = { width: 1920, height: 1080 };
page.open("http://www.google.com", function start(status) {
page.render('google_home.png');
phantom.exit();
but, when i set the dimension as
page.viewportSize = { width: 320, height: 780 };
the resulting image width is 602px.
how to set width for taking screenshot using page.render() function?