Javacadabra
Javacadabra

Reputation: 5768

Facebook needs PHP Curl Extension issue with php.ini file

I am trying to setup a local version of a website that I can do some testing on. Currently when I open the site in my browser I get this php error:

( ! ) Exception: Facebook needs the CURL PHP extension. in C:\wamp\www\mysie.tld\includes\facebook-graph\base_facebook.php on line 19

So I did a bit of reading up and saw that this was most likely due to my WAMPserver not having the extension enabled for PHP. I did a phpinfo() and this output the .ini file that was being loaded.

C:\wamp\bin\apache\apache2.4.2\bin\php.ini

I opened this file up in my text editor and removed the semi colon before this line:

extension=php_curl.dll

I then restarted the WAMPServer and reloaded my site. Unfortunately, the error persisted and I do not know what I can do to fix it! Any help would be much appreciated.

Upvotes: 1

Views: 102

Answers (1)

Javacadabra
Javacadabra

Reputation: 5768

Managed to figure it out with a quick scan through some similar questions on SO. If anyone is running into the same issue it was due to a bug in the curl.dllfile that came with WAMP 2.2. In order to rectify the issue I downloaded the php_curl-5.4.3-VC9x64.zip from this link:

https://code.google.com/p/justintung/downloads/detail?name=php_curl-5.4.3-VC9-x64.zip&can=2&q=

I then moved and replaced the curl.dll file in the downloaded folder with the curl.dll file located in my php ext directory.

Restarted WAMP and the problem was resolved.

Upvotes: 1

Related Questions