首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >CutyCapt不适用于闪存

CutyCapt不适用于闪存
EN

Stack Overflow用户
提问于 2015-01-08 22:13:10
回答 1查看 584关注 0票数 3

我试图用cutycapt捕获一些包含Adobe Flash元素的网站,但没有运气。

我的PHP脚本:

代码语言:javascript
复制
$url=escapeshellarg($url);
$filename=escapeshellarg($filenamebase);
$format=escapeshellarg($format);
$useragent=escapeshellarg($useragent);

$cmd = "xvfb-run --server-args=\"-screen 0, ".$width."x".$height."x24\" CutyCapt --url=$url --out=$filename --out-format=$format --user-agent=$useragent --plugins=\"on\" --delay=5000 --javascript=$js";

exec($cmd);

例如,如果我想要捕获http://flashhry.cz/h/kingdom-rush,我的脚本将在shell中运行以下命令:

代码语言:javascript
复制
xvfb-run --server-args="-screen 0, 1024x5000x24" CutyCapt --url='http://sk.search.etargetnet.com/cookie.php?eURL=http%3A%2F%2Fflashhry.cz%2Fh%2Fkingdom-rush' --out='./screens/http_flashhry.cz_h_kingdom-rush.png' --out-format='png' --user-agent='Mozilla/5.0 (Windows NT 6.3; rv:36.0) Gecko/20100101 Firefox/36.0' --plugins="on" --delay=5000 --javascript=on

输出(http://prntscr.com/5pxc7e)没有闪存

命令stdout为:

代码语言:javascript
复制
Xlib:  extension "RANDR" missing on display ":99".

无错误输出。

我需要它在Ubuntu6服务器上运行,但我的CentOS桌面也有类似的结果。

EN

回答 1

Stack Overflow用户

发布于 2015-01-21 06:42:08

https://github.com/jaequery/php-site-screenshot

也请注意Ubuntu的安装脚本。它可能还会让您对CentOS的依赖关系有一个了解。

https://github.com/jaequery/cutycapt-installer-script-on-ubuntu/blob/master/install

如果它仍然失败,我会认为CentOS 6可能太旧了,不能满足要求。

票数 -1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/27842154

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档