Reputation: 4316
I can't get cURL to work from inside Apache by any means. It's actually fairly strange too provided that:
Additionally, when I built PHP, I opted the "--enable-curl" flag.
Upvotes: 3
Views: 1798
Reputation: 1993
I had similar problem - worked from cli, silently failed from Apache 2.4
I've tried:
1) copying ssleay32.dll and libeay32.dll from php folder into apache\bin folder - didn't work
2) deleting ssleay32.dll and libeay32.dll from apache\bin folder completely - WORKED.
You should restart apache server each time you make change to make it work.
Also you should install both x86 and x64 versions of C++ Resistributable Visual Studio from Microsoft.
Upvotes: 0
Reputation: 291
I had same problem after installing php5-curl. I rebooted apache and that fixed it.
sudo /etc/init.d/apache2 restart for ubuntu 12.04
Upvotes: 0
Reputation: 2904
You are probably not loading the extension in the appropriate php.ini
. The file should include something like:
[PHP_CURL]
extension=php_curl.dll
Also, --enable-curl
is not a PHP configure option. --with-curl=[DIR]
is the one you'd want. Check out the cURL installation instructions.
php_curl.dll
should be inside PHP's ext
directory when configured correctly.
Upvotes: 2