messagerie-melanie2 / Roundcube-Plugin-Roundrive

Plugin based on kolab_file plugin to connect to a webdav server
4 stars 12 forks source link

Call to undefined function Sabre\HTTP\curl_init() #1

Closed ychaouche closed 8 years ago

ychaouche commented 8 years ago

Hi !

Just installed roundrive and this is my first error :

[15-Jun-2016 17:37:26 Africa/Algiers] PHP Fatal error: Call to undefined function Sabre\HTTP\curl_init() in /var/www/roundcubemail-1.1.4/plugins/roundrive/lib/vendor/sabre/http/lib/Sabre/HTTP/Client.php on line 307 curl extension is enabled and call for that function from the command line works fine.

root@messagerie[CHROOT][10.10.10.20] ~ # php -r "phpinfo();" | grep -i curl
/etc/php5/cli/conf.d/20-curl.ini,
curl
cURL support => enabled
cURL Information => 7.38.0
root@messagerie[CHROOT][10.10.10.20] ~ #

Just making sure that if curl_init wasn't defined I'd get a "call to undefined function" error.

root@messagerie[CHROOT][10.10.10.20] ~ # php -r "curldzadzadzadzadzadza_init();"
PHP Fatal error:  Call to undefined function curldzadzadzadzadzadza_init() in Command line code on line 1
root@messagerie[CHROOT][10.10.10.20] ~ # php -r "curl_init();"
root@messagerie[CHROOT][10.10.10.20] ~ # 
tpayen commented 8 years ago

Hmm this is strange, is curl also enable in your php apache configuration (I think in : /etc/php5/apache2/conf.d/20-curl.ini) ? Or maybe there is a problem with your chroot environnement ?

ychaouche commented 8 years ago

Here's 20-curl.ini

root@messagerie[CHROOT][10.10.10.20] ~ # cat /etc/php5/apache2/conf.d/20-curl.ini ; configuration for php CURL module
; priority=20
extension=curl.so
root@messagerie[CHROOT][10.10.10.20] ~ # 

Also for the chroot it is already running phpmyadmin and roundcube just fine, so can't really tell it if it is from the chroot or not but I'm confident that it is generally well configured to run at least these two php projects.

ychaouche commented 8 years ago

I thought maybe PHP is looking for the curl_init function somewhere in Sabre\HTTP\ instead of another location where it should be defined (the curl extension) ?

ychaouche commented 8 years ago

Sorry my mistake forgot to restart apache :-1: