【发布时间】:2018-01-10 21:50:34
【问题描述】:
我在 laravel 中使用 casperjs 和 phantom js
putenv('PHANTOMJS_EXECUTABLE='.config('hs.PHANTOMJS'));
$js_path = \resource_path('assets/js/main.js');
$jquery_path = \base_path('node_modules/jquery/dist/jquery.min.js');
$link = 'www.example.com';
$response = shell_exec(config('hs.CASPERJS').' ' . $js_path . ' "' . $link . '" "' . $jquery_path . '"');
我在另一台服务器上运行此代码,一切正常
但现在我在刚刚创建的新服务器上运行它并收到分段错误消息
我尝试运行
/var/www/myuser/data/phantomjs/phantomjs-2.1.1-linux-x86_64/bin/phantomjs --version
并得到同样的错误 但在另一台服务器上一切正常
【问题讨论】:
标签: php laravel phantomjs casperjs