捕获特定于浏览器的网页渲染?
有什么方法可以捕获(图像、pdf 等)网页在 chrome 或 IE 中的外观吗?我猜对于不同的浏览器会有不同的方法来做到这一点,但是有没有 API、库或插件可以做到这一点?
Is there any way to capture (image, pdf etc) how a webpage will look like in lets say chrome or I.E? I am guessing there will be different ways to do this for different browsers but is there any API, library or addon that does this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
使用 selenium webdriver (有一个 python api) 来远程控制浏览器和 截取屏幕截图。据我所知,支持所有主要浏览器。
Use selenium webdriver (has a python api) to remote control a browser and take a screenshot. Supports all major browsers as far as I'm aware.
是的,很少有精彩的网站提供这种服务,也有一些原始的到一些高级的 API 服务来捕获浏览器屏幕截图。
Browsershots.org
大多数时候它的速度相当慢,可能是因为它必须承受繁重的交通。然而,它是最好的屏幕截图提供商之一。
[LINK]http://browsershots.org/xmlrpc/ 检查此网址以了解如何使用基于 XMLRPC 的 API 进行浏览器截图。
如果您想要一些原始且直接的缩略图服务,以下网站可能适合您。
http://www.thumbalizr.com/
http://api1.thumbalizr.com/?url=http://acpmasquerade.com&width=some_width
我检查了另一个网站 webshotspro.com,当我在其中排队获取快照时,它说我的队列落后于 7053 个其他请求。加载图标不断旋转:P
尝试使用 Browsershots.org 的 XMLRPC 调用
Yes there are few wonderful websites providing this service and also some kinds of primitive to some advanced API services for capturing browser screenshots.
Browsershots.org
Its quite slow most of the times, may be due to the heavy traffic it has to withstand. However its one of the best screenshots provider.
[LINK]http://browsershots.org/xmlrpc/ Check this url to understand how to use the XMLRPC based API for browsershots.
And if you want some primitive and straight forward type thumbnailing services, may be the following sites work good for you.
http://www.thumbalizr.com/
http://api1.thumbalizr.com/?url=http://acpmasquerade.com&width=some_width
I checked another website webshotspro.com and when I queued one for a snapshot, it said my queue was behind 7053 other requests. the loading icon keeps rotating :P
Give a try with the XMLRPC call from Browsershots.org