douzhou7124 2013-01-14 08:30
浏览 38

HTTP标头规范

I am trying to send/receive requests using PHP's fsockopen().

I just wanted to ask what are the required headers for different types of HTTP methods?

these are Google's response header

HTTP/1.0 200 OK => 
Date => Mon, 14 Jan 2013 08:21:29 GMT 
Expires => -1 
Cache-Control => private, max-age=0 
Content-Type => text/html; charset=ISO-8859-1 
Set-Cookie => NID=67=LI2GVi9aUXjLjdpqEs4zbEwYAWmMsW_5CQBWKeR-cohs2CLBSGN7rXqFplRNGxiF2oOZpGWR1mvBPhX7Eak4nmkNERiwPiitJNc0ub4kCxKZt64zvxcZXaeIjdANAWDa; expires=Tue, 16-Jul-2013 08:21:29 GMT; path=/; domain=.google.com; HttpOnly 
P3P => CP="This is not a P3P policy! See http://www.google.com/support/accounts/bin/answer.py?hl=en&answer=151657 for more info." 
Server => gws 
X-XSS-Protection => 1; mode=block 
X-Frame-Options => SAMEORIGIN

can you give me a hint what headers are required in order to make a request?

  • 写回答

1条回答 默认 最新

  • douji1877 2013-01-14 08:32
    关注

    This is not easy topic, but you will probably find best answer in RFC2616 which standarizes HTTP/1.1 protocol.

    http://www.w3.org/Protocols/rfc2616/rfc2616.html

    评论

报告相同问题?

悬赏问题

  • ¥15 Oracle触发器记录修改前后的字段值
  • ¥100 为什么这个恒流源电路不能恒流?
  • ¥15 有偿求跨组件数据流路径图
  • ¥15 写一个方法checkPerson,入参实体类Person,出参布尔值
  • ¥15 我想咨询一下路面纹理三维点云数据处理的一些问题,上传的坐标文件里是怎么对无序点进行编号的,以及xy坐标在处理的时候是进行整体模型分片处理的吗
  • ¥15 CSAPPattacklab
  • ¥15 一直显示正在等待HID—ISP
  • ¥15 Python turtle 画图
  • ¥15 stm32开发clion时遇到的编译问题
  • ¥15 lna设计 源简并电感型共源放大器