sudo apt-get install php5-curl
重启php-cgi
sudo /etc/init.d/php-fpm restart
编译安装的情况下:
cd /opt/build/php-5.2.13/ext/curl
sudo /usr/local/php/bin/phpize
sudo ./configure --with-php-config=/usr/local/php/bin/php-config
sudo make
sudo make install
修改php.ini的配置文件:
在extension_dir = "/usr/local/php/lib/php/extensions/"
下面添加:
extension = "curl.so"
sudo /etc/init.d/php-fpm restart
阅读(227) | 评论(0) | 转发(0) |