Installing some PHP source code such as Cmstop needs the system to turn on the curl extension, which needs to modify the PHP configuration, in Windows only three simple steps.
One, window under the installation of Php_curl support
1. Php_curl.dll the three files under the PHP installation folder (possibly in the Ext folder), Libeay32.dll,ssleay32.dll copy to%windir%/system32;
2. Open PHP.ini (may be in the installation directory of the PHP environment, by default in the C:\WINDOWS directory), the Extension=php_curl.dll head of the semicolon removed;
3. Restart the PHP service (Apache or IIS), such as restarting IIS and running IISRESET.
Ii. How PHP Installs Curl extensions in Linux
If PHP has been compiled in the system, and then need to add a new extension, one way is to re-compile PHP completely, the other way is to compile the extension library separately, in the form of extension extension.
Situation one: New installation of PHP and curl
First Download the Curl installation package (my php is 4.4.4, download the latest Curl 7.16 can not be used, the last download 7.14 only, download to pay attention to the version)
Then install Curl
# TAR-ZXF (fill in the Download Curl package name here) #./configure–prefix=/usr/local/curl# make; Make install
When you install PHP, just turn on the switch –with-curl=/usr/local/curl.
PHP requires the directory of Curl to have the include and Lib directories, and include under the Easy.h and curl.h two files, Lib to have libcurl.a. The files under the compiled include are available, but they may not be available in the Lib directory. Originally generated to the Lib/.libs directory, so copy to the Lib directory.
Scenario Two: PHP is already installed, and now you need to add this extension
To install the original PHP source directory, (if deleted, but also the original compressed files, re-unzip the line)
CD ext/curlphpize ./configure–with-curl=dir (Can not write dir, if your curl is not specified when installing the directory) make
The curl.so file is generated under phpdir/ext/curl/moudles/.
Copy the curl.so file to the extensions configuration directory and modify the php.ini.
The above two are the Linux PHP Extension Curl installation method.
Install and turn on Curl Extensions for PHP