CURL.1 manual page
Name
Curl-transfer a URL
Summary
curl[options] [URL ...]
Describe
CURL is a tool that transmits data to or from the server, which supports HTTP, HTTPS,
Protocols such as FTP, FTPS, SCP, SFTP, TFTP, DICT, TELNET, LDAP, or
Introduction to PHP's Curl library and examples of using Phpcurl Library
Using the PHP Curl Library, you can easily and effectively grab pages. You just need to run a script, then analyze the page you crawled, and then you can get the data you want
PHP can use the file_get_content () function to crawl Web content, but it cannot do more complex processing, such as uploading or downloading files, Cookie manipulation, and so on. And PHP's CURL provides these features.
First, Curl
At first Curl was designed as a command-line tool, and fortunately, PHP also supports curl. With curl, we can freely send HTTP requests to a URL to fetch or submit data in a PHP program, and support many other protocols such as Ftp,telnet and SMTP.
[network Programming] PHP curl a few examples
Using the PHP Curl Library, you can easily and effectively grab pages. You just need to run a script, then analyze the page you crawled, and then you can get the data you want in a program. Whether you
Using the PHP curl library, you can easily and effectively grab Pages. You just need to run a script, then analyze the page you crawled, and then you can get the data you want in a Program. Whether you want to take part of the data from a link, or
At first Curl was designed as a command-line tool, and fortunately, PHP also supports curl. By Curl This tool, we can freely send HTTP requests to a URL to obtain or submit data in a PHP program, and support many other protocols, such as
Using the PHP Curl Library, you can easily and effectively grab pages. You just need to run a script, then analyze the page you crawled, and then you can get the data you want in a program. Whether you want to take part of the data from a link, or
First, the advantages of curlYou might say that in PHP you can easily get the content of a URL, as long as through the File_get_contents,file or ReadFile function can be easily implemented, do not have to use the curl:
Copy Code code as
curl_setopt--Sets an option for the curl callDescribe BOOL curl_setopt (INT-ch, string option, mixed value) The curl_setopt () function sets the option for a curl session. The option parameter is the setting you want, and value is the values
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.