网创优客建站品牌官网
为成都网站建设公司企业提供高品质网站建设
热线:028-86922220
成都专业网站建设公司

定制建站费用3500元

符合中小企业对网站设计、功能常规化式的企业展示型网站建设

成都品牌网站建设

品牌网站建设费用6000元

本套餐主要针对企业品牌型网站、中高端设计、前端互动体验...

成都商城网站建设

商城网站建设费用8000元

商城网站建设因基本功能的需求不同费用上面也有很大的差别...

成都微信网站建设

手机微信网站建站3000元

手机微信网站开发、微信官网、微信商城网站...

建站知识

当前位置:首页 > 建站知识

安装CURL-创新互联

CURL是用于发出网络请求的命令行工具,支持多种协议。也是测试api的利器。

成都创新互联公司专注骨干网络服务器租用10年,服务更有保障!服务器租用,内蒙古服务器托管 成都服务器租用,成都服务器托管,骨干网络带宽,享受低延迟,高速访问。灵活、实现低成本的共享或公网数据中心高速带宽的专属高性能服务器。

常用功能有:

  1. 查看网页源码:curl www.xxx.xxx

  2. 保存网页:curl -o www.xxx.xxx

  3. 自动跳转:curl -L www.xxx.xxx

  4. 显示头信息:curl -i www.xxx.xxx

  5. 显示通讯过程: curl -v www.xxx.xxx, 或保存更详细的通讯过程到输出文件:curl --trace outout.txt www.xxx.xxx

  6. 发送表单信息:

    1. GET: curl tvbs.cc/form.cgi?data=xxx

    2. POST: curl --data "key=value" tvbs.cc/form.cgi

  7. 文件上传

  8. Referer字段

  9. User Agent字段

  10. Cookie

  11. 增加头信息

  12. Http认证

更多的详细的命令查看:https://curl.haxx.se/docs/httpscripting.html

在linux中的安装命令:

lybing@ubuntu:/usr/local/tutorial$ sudo apt-get install curl
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  libcurl3
The following NEW packages will be installed:
  curl
The following packages will be upgraded:
  libcurl3
1 upgraded, 1 newly installed, 0 to remove and 23 not upgraded.
Need to get 123 kB/296 kB of archives.
After this operation, 314 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://us.archive.ubuntu.com/ubuntu/ trusty-updates/main curl amd64 7.35.0-1ubuntu2.7 [123 kB]
Fetched 107 kB in 17s (6,013 B/s)                                              
(Reading database ... 179037 files and directories currently installed.)
Preparing to unpack .../libcurl3_7.35.0-1ubuntu2.7_amd64.deb ...
Unpacking libcurl3:amd64 (7.35.0-1ubuntu2.7) over (7.35.0-1ubuntu2.6) ...
Selecting previously unselected package curl.
Preparing to unpack .../curl_7.35.0-1ubuntu2.7_amd64.deb ...
Unpacking curl (7.35.0-1ubuntu2.7) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Setting up libcurl3:amd64 (7.35.0-1ubuntu2.7) ...
Setting up curl (7.35.0-1ubuntu2.7) ...
Processing triggers for libc-bin (2.19-0ubuntu6.9) ...
bing@ubuntu:/usr/local/tutorial$

另外有需要云服务器可以了解下创新互联scvps.cn,海内外云服务器15元起步,三天无理由+7*72小时售后在线,公司持有idc许可证,提供“云服务器、裸金属服务器、高防服务器、香港服务器、美国服务器、虚拟主机、免备案服务器”等云主机租用服务以及企业上云的综合解决方案,具有“安全稳定、简单易用、服务可用性高、性价比高”等特点与优势,专为企业上云打造定制,能够满足用户丰富、多元化的应用场景需求。


网页题目:安装CURL-创新互联
文章地址:http://bjjierui.cn/article/dpeheg.html

其他资讯