Curl:修订间差异
跳到导航
跳到搜索
此页面具有访问限制。如果您看见此消息,则说明您没有权限访问此页面。
无编辑摘要 |
(→範例) |
||
第7行: | 第7行: | ||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
curl -v --proxy https://username:password@proxy.example.com:4128/ https://httpbin.org/ | curl -v --proxy https://username:password@proxy.example.com:4128/ https://httpbin.org/anything | ||
</syntaxhighlight> | |||
指定referer可以用<code>-X</code>: | |||
<syntaxhighlight lang="bash"> | |||
curl -v -H "Referer: https://www.example.com/" https://httpbin.org/anything | |||
</syntaxhighlight> | </syntaxhighlight> | ||
2024年3月11日 (一) 07:03的版本
curl是一套工具,包括library以及command line tool。
范例
指定proxy可以用--proxy
并且包含proxy需要的账号密码:
curl -v --proxy https://username:password@proxy.example.com:4128/ https://httpbin.org/anything
指定referer可以用-X
:
curl -v -H "Referer: https://www.example.com/" https://httpbin.org/anything
外部链接
- 官方网站 (英文)