當前位置:編程學習大全網 - 電腦編程 - delphi idhttp 怎麽自定義http消息頭

delphi idhttp 怎麽自定義http消息頭

idpatible;?MSIE?6.0;?Windows?NT?5.2;?SV1;?.NET?CLR?1.1.4322;?.NET?CLR?2.0.50727)

Content-Type:?application/x-www-form-urlencoded

Host: 網址

Content-Length:?52

Expect:?100-continue

除 Agent 等可以直接在 idHttp 屬性中進行設置:

自定義頭部在?CustomHeaders 中進行定義:

用代碼定義其中的 Expect 如下:

IdHTTP1.Request.CustomHeaders.Values['expect']?:=?'100-continu';

  • 上一篇:編程有趣的問題
  • 下一篇:自己測試了SCL90,但是看不懂,求解答是什麽情況
  • copyright 2024編程學習大全網