WAMP Curl installation

与世无争的帅哥 提交于 2019-11-29 04:11:26

Make sure that you have uncommented the extension from the right php.ini file. You should check whether or not extension is enabled through phpinfo() command.

Or even simpler, click the wamp icon in the notification area (bottom right of your screen), go through PHP > PHP extensions and click the second item 'php_curl'. Wamp will restart automatically.

I ran into the same issue and i solved it just unistalling wamp2_x64(first installed in c:\wamp) and reinstalling wamp_x86 in the folder C:/Program Files (x86)/wamp.

That seems to solve the problem, I guess it might be a problem with the dlls for 64 bits.

The php_curl.dll in a certain package of WAMP server was the wrong file, I had the same problem, I found the correct php_curl.dll file in /wamp/bin/php/php[youversion/ext/ and replaced it and it worked. See this article: http://forum.wampserver.com/read.php?2,85716

Abhishek Rakshit

Had same issue with 64 bit Windows 7. This is what worked for me.

Answered by Soren from another SO thread - CURL for WAMP

"There seems to be a bug somewhere. If you are experiencing this on Win 7 64 bit then try installing apache addon version 2.2.9 and php addon version 5.3.1 and switching to those in WAMP and then activating the CURL extension. That worked for me."

I had the same problem with Wampserver 2.2 (64 bit). Here's what I did to get it working:

1) Go to wampserver->PHP->PHP extensions, enable the php_curl extension

2) Open \bin\php\php5.3.13\php.ini and uncomment the following line: extension=php_curl.dll

3) Go to \bin\php and copy libeay32.dll and ssleay32.dll into your windows\system32 folder

4) If you try and restart wampserver's services, you'll notice that lib_curl still doesn't work. Turns out that the version of php_curl.dll bundled in the pack is not compiled correctly.

Apache's error log contained the following:

Warning: PHP Startup: Unable to load dynamic library

'c:/wamp/bin/php/php5.3.13/ext/php_curl.dll' - The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log or use the command-line sxstrace.exe tool for more detail.

5) You'll need a properly compiled version of php_curl.dll. I downloaded php_curl-5.3.13-VC9-x64.zip from this blog post:

[www.anindya.com]

Direct link:

[www.mediafire.com]

I replaced php_curl.dll inside \bin\php\php5.3.13\ext with the one above, and everything worked fine smiling smiley 6) To test if the cURL extension is working for you, try this code snippet

`

<?php
error_reporting(E_ALL);
ini_set('display_errors', '1');
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,
'http://news.google.com/news?hl=en&topic=t&output=rss');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
$contents = curl_exec ($ch);
echo $contents;
curl_close ($ch);
?>

`

Here's another post with similar info (I found this after I wrote these instructions): [www.o3n.org]

shyammakwana.me

if you have already uncommented line from php.ini and still getting error than you should make sure that this extension file is exists in php folder or not

so check for this file

php_curl.dll

in

{wamp}\bin\php\php5.x.x\ext\

if it's not there than download it from internet and paste it to there

Restart Apache.

  • download curl for windows (http://curl.haxx.se/download.html)
  • Paste the zip file content into C:\wamp\bin\apache\apache2.2.x
  • Locate and open your php.ini file (resides in C:\wamp\bin\php\php5.x)
  • In your php.ini file, change/ uncomment the following line: ;extension=php_curl.dll (you do so by removing the semi-colon)
  • restart Apache or the whole server to enjoy
Gainster

this sloved my problem

  1. Stop WAMP completely.
  2. Find your WAMP folder C:\Path\To\WAMP\bin\Apache\ApacheVersion\bin\
  3. Edit that php.ini and uncomment extension=php_curl.dll
  4. Restart WAMP.

That should hopefully solve it.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!