且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Windows 7 64位和Apache下的PHP和CURL

更新时间:2023-02-22 18:56:26

AFAIR,您需要 PATH 上的 libeay32.dll 和 libssl32.dll 文件才能使 Curl 正常工作.您的 x64 系统可能是 64 位.

I'm trying to use curl with PHP on my box without any success.

My Config :


OS : win 7 64 bits,

PHP : 5.3.1,

Apache : 2.2.14


I was able to use the mysql extension, so the configuration of my php.ini seems fine. But I get and error in Apache log with curl :

PHP Warning: PHP Startup: Unable to load dynamic library 'C:/php-5.3.1/ext/php_curl.dll' - The specified module could not be found. in Unknown on line 0

The file is right there, and it's loading php_mysql.dll without any problem.

I tried everything : to put the dll file in apachein, windowssystem32, put the path of the php EXT in the PATH environment variable. to put some lib (libeay.dll and sssomething.dll) in windows 32

Well, I think this might have something to do with my Windows being 64 bits or with the version of PHP.. maybe. I don't know anymore :(

Any idea?

Update I'm not using Wamp because I like to know what I do to my system, and ultimately choose the version that I want of apache, php and MySql.

My Solution

I added the path of PHP in my PATH environement variable and it worked. I'll try to find out what was the DLL needed.

Update : Well it looks like it was libeay32.dll and sslleay32.dll had to be in the PATH environment variable. I added to the bin subdirectory of Apache and it worked.

AFAIR, you need libeay32.dll and libssl32.dll files on PATH for Curl to work properly. And probably 64 bit for your x64 system.