zoukankan      html  css  js  c++  java
  • http基础

    1.http由五部分组成:请求行/状态行、通用头、请求头/响应头、实体头、实体主体
    http请求:请求行 eg1:GET /index.html HTTP/1.1 eg2:POST http://ip/index.html HTTP/1.1
    +通用头,请求头 eg:Host、user-Agent、Accept

    +空行CRCF

    +post实体头
    +post实体内容eg: user=a&pwd=b


    http响应:状态行 eg:HTTP/1.1 200 OK
    +通用头,响应头 eg:Content-Type、Content-lenght

    +空行CRCF
    +实体头 eg:Content-Type:text/html、Content-lenght
    +实体内容


    缓存:减少请求、减少响应内容大小;Expires、Cache-control、last-Modified vs if-Modified-Since、ETag vs if-None-Match
    proxy服务器:在用户浏览器 vs proxy服务器 vs 各大网站服务器

  • 相关阅读:
    SGU 194. Reactor Cooling(无源汇有上下界的网络流)
    SGU 197.Nice Patterns Strike Back
    Codeforces 474E
    记一个问题的AC
    UVM Primer
    UVM Primer
    UVM Primer
    UVM Primer
    UVM Primer
    UVM Primer
  • 原文地址:https://www.cnblogs.com/toven/p/2674065.html
Copyright © 2011-2022 走看看