PhantomJS - 'unsafe-eval' is not an allowed source of script in the following Content Security Policy directive

穿精又带淫゛_ 提交于 2019-12-04 03:22:44

问题


I'm trying to change the value of a input with PHP webdriver and PhantomJS. When I run a simple

$driver->executeScript("document.getElementById('changeme').value='".$newvalue."' ;", array());

I get the following error

Refused to evaluate a string as JavaScript because unsafe-eval is not an allowed source of script in the following Content Security Policy directive

I've got the following command line options set

--ignore-ssl-errors=true --web-security=false --ssl-protocol=any

Any suggestions?

来源:https://stackoverflow.com/questions/28593216/phantomjs-unsafe-eval-is-not-an-allowed-source-of-script-in-the-following-co

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!