phantomjs命令行截图疑问
发布于 9 年前 作者 chapgaga 5667 次浏览 最后一次编辑是 8 年前 来自 问答

有人通过命令行调用过phantomjs么? 按下面教程,你们能正确运行将页面转为pdf的命令么?

教程: http://phantomjs.org/screen-capture.html

phantomjs rasterize.js http://ariya.github.io/svg/tiger.svg tiger.png phantomjs rasterize.js http://raphaeljs.com/polar-clock.html clock.png 都运行正确

phantomjs rasterize.js ‘http://en.wikipedia.org/w/index.php?title=Jakarta&printable=yes’ jakarta.pdf 报了奇怪的错误

phantomjs rasterize.js ‘http://en.wikipedia.org/w/index .php?title=Jakarta&printable=yes’ jakarta.pdf Usage: rasterize.js URL filename [paperwidthpaperheight|paperformat] [zoom] paper (pdf output) examples: "5in7.5in", “10cm20cm", “A4”, "Letter" image (png/jpg output) examples: “1920px” entire page, window width 1920px "800px600px” window, clipped to 800x600 ’printable’ 不是内部或外部命令,也不是可运行的程序 或批处理文件。

回到顶部