Ubuntu 安装 PHP cURL

Ubuntu 安装 PHP cURL

如果你在用PHP, 你可能需要用到cURL, 这是其中最流行的插件. PHP CURL插件需要通过libcurl来实现, Daniel Stenberg创建的一个库, 能够和许多不同类型协议的web服务器进行通信连接。
架设你已经安装了LAMP. 需要安装cURL 在你的Linux计算机上,比如Ubuntu,运行一下命令行在终端:

sudo apt-get install curl libcurl3 libcurl3-dev php5-curl

安装完毕之后,需要重新启动apache, 在终端运行命令:

sudo /etc/init.d/apache2 restart

我已经试过,非常行!

下面是我看到的英文原文:
If you use PHP, you may need to use cURL, which is one of the most popular extension. PHP CURL functions are available through the use of libcurl, a library created by Daniel Stenberg, and allow you to connect and communicate with web servers using many
different types of protocols.

Assume you have already setup LAMP. To install or setup cURL on your Linux machine like Ubuntu, run the following line of shell command in your terminal:

sudo apt-get install curl libcurl3 libcurl3-dev php5-curl

Now you have PHP cURL installed, the next thing you need to do is to restart apache2, run the following command in your terminal:

sudo /etc/init.d/apache2 restart


原创文章,作者:ItWorker,如若转载,请注明出处:https://blog.ytso.com/31884.html

(0)
上一篇 2021年7月25日
下一篇 2021年7月25日

相关推荐

发表回复

登录后才能评论