Install php extension cURL in Linux

Source: Internet
Author: User

As a mature and stable operating system, Linux has many advantages. So most people learn about the Linux operating system. This article describes how to install php extension cURL in Linux. I hope you can learn how to install php extension cURL in Linux.

Method 1

Install cURL

 
 
  1. # wget  
  2. http://curl.haxx.se/download/curl-7.17.1.tar.gz  
  3. [url=http://curl.haxx.se/download/curl-7.15.0.tar.gz][/url]  
  4. # tar -zxf curl-7.17.1.tar.gz  
  5. # ./configure –prefix=/usr/local/curl  
  6. # make; make install 

Install php
Just enable the switch-with-curl =/usr/local/curl
You can.
This extended library is a great alternative to fsockopen and so on.

Method 2

Go to the source code directory for installing the original php,

 
 
  1. cd ext  
  2. cd curl  
  3. phpize  
  4. ./configure –with-curl=DIR 
  5. make 

The curl. so file is generated under PHPDIR/ext/curl/moudles.
Copy the curl. so file to the extensions configuration directory and modify php. ini.

The above two methods are used to install php extension cURL in Linux.

  1. Easily connect to the campus network using Linux
  2. Fully Understand Linux Process Technology
  3. Introduction to the password command in Linux
  4. Learn about Linux regulatory commands
  5. How to view the ps-aux command of all processes in Linux

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.