zoukankan      html  css  js  c++  java
  • 服务器响应HTTP请求状态码(转)

    当服务器响应HTTP请求时,其状态行的信息为HTTP的版本号,状态码,及解释状态码的简单说明:
    
    1、客户方错误:
       100   客户必须继续发出请求
       101   客户要求服务器根据请求转换HTTP协议版本
    2、成功:
       200   OK
       201   已创建
       202   接收
       203   非认证信息
       204   无内容
       205   重置内容
       206   部分内容
    3、重定向:
       300   多路选择
       301   永久转移
       302   暂时转移
       303   参见其它
       304   未修改(Not Modified)
       305   使用代理
    4、客户方错误:
       400   错误请求(Bad Request)
       401   未认证
       402   需要付费
       403   禁止(Forbidden)
       404   未找到(Not Found)
       405   方法不允许
       406   不接受
       407   需要代理认证
       408   请求超时
       409   冲突
       410   失败
       411   需要长度
       412   条件失败
       413   请求实体太大
       414   请求URI太长
       415   不支持媒体类型
    5、服务器错误:
       500   服务器内部错误
       501   未实现(Not Implemented)
       502   网关失败
       503   服务器过载或暂停维修
       504   网关超时
       505   HTTP版本不支持
    
    $codeArr = array(
        100=>'Continue',
        101=>'Switching Protocols',
        200=>'OK',
        201=>'Created',
        202=>'Accepted',
        203=>'Non-Authoritative Information',
        204=>'No Content',
        205=>'Reset Content',
        206=>'Partial Content',
        300=>'Multiple Choices',
        301=>'Moved Permanently',
        302=>'Found',
        303=>'See Other',
        304=>'Not Modified',
        305=>'Use Proxy',
        307=>'Temporary Redirect',
        400=>'Bad Request',
        401=>'Unauthorized',
        402=>'Payment Required',
        403=>'Forbidden',
        404=>'Not Found',
        405=>'Method Not Allowed',
        406=>'Not Acceptable',
        407=>'Proxy Authentication Required',
        408=>'Request Timeout',
        409=>'Conflict',
        410=>'Gone',
        411=>'Length Required',
        412=>'Precondition Failed',
        413=>'Request Entity Too Large',
        414=>'Request-URI Too Long',
        415=>'Unsupported Media Type',
        416=>'Requested Range Not Satisfiable',
        417=>'Expectation Failed',
        500=>'Internal Server Error',
        501=>'Not Implemented',
        502=>'Bad Gateway',
        503=>'Service Unavailable',
        504=>'Gateway Timeout',
        505=>'HTTP Version Not Supported',
    );
  • 相关阅读:
    C语言I博客作业04
    PTA一般问题汇总与解答
    C语言I博客作业03
    C语言I博客作业02
    C语言I—2019秋作业第一周作业
    C语言I博客作业03
    C语言I博客作业02
    第一周作业
    【2017下集美大学软工1412班_助教博客】团队作业8——测试与发布成绩公示
    《构建之法》读书笔记第8章——需求分析
  • 原文地址:https://www.cnblogs.com/fxfly/p/4650265.html
Copyright © 2011-2022 走看看