Reputation: 20845
When I try to use the program /usr/bin/curl
from within PHP I get the error
Warning: file_exists(): open_basedir restriction in effect. File(/usr/bin/curl) is not within the allowed path(s): (/usr/share/php/:/tmp/:/usr/share/pear/) in /var/www/check.inc.php on line 138
How can i enable this on debian wheezy with PHP 5.4?
Upvotes: 2
Views: 97
Reputation: 20845
it worked by adding the path to curl to the ini.include-path:
I added this line in my apache config for this site:
php_admin_value open_basedir "/usr/share/php/:/tmp/:/usr/share/pear/:/usr/bin/curl"
Upvotes: 2