Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/289.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如果从php调用,python webdriver将不会运行_Php_Python 2.7 - Fatal编程技术网

如果从php调用,python webdriver将不会运行

如果从php调用,python webdriver将不会运行,php,python-2.7,Php,Python 2.7,我正在尝试从php执行python脚本。它在webdriver被称为[pytest.py]的行停止工作: path_to_chromedriver = '/home/user/Desktop/2014/programs/chromedriver/chromedriver' # change path as needed #i can print out something here (e.g. print 'hello') but not after the next line br = web

我正在尝试从php执行python脚本。它在webdriver被称为[pytest.py]的行停止工作:

path_to_chromedriver = '/home/user/Desktop/2014/programs/chromedriver/chromedriver' # change path as needed
#i can print out something here (e.g. print 'hello') but not after the next line
br = webdriver.Chrome(executable_path = path_to_chromedriver)
这就是PHP调用python脚本[phptest.PHP]的方式:

$eventid_arg = $_REQUEST['eventid'];
$pyresponse_str = system("python pytest.py $eventid_arg", $retval);

用户是否具有运行python webdriver所需的权限?权限很好。