http method and status code
http method
- HEAD: 只返回相应的header
- POST: 一般用于提交表单
- PUT: 向Web服务器上传文件
- GET: 查
- DELET: 删除
status code
- 1xx与2xx: 返回提示信息
- 3xx: 重定向
- 4xx: 客户端错误
- 5xx: 服务器端错误
具体
- 200: OK
- 204: No Content, 请求的资源没有body
- 206: Partial Content, 部分内容, 使用206状态码实现断点续传, 在206的response中有一个Range字段, 他的值是一个数据的范围
- 301: Move permanently, 永久重定向, 在301中有Location字段, 它的值为新的URL让浏览器自动去访问, 原来的资源是永远无效的
- 302: Found, 临时重定向, 在当前资源可以访问, 但是需要先访问在302中字段名为Location的URL才行, 典型的就是我们提前访问了需要用户登录才能访问的URL
- 304: Not Modified, 告诉客户端当前访问的资源没有更新, 可以使用缓存在内存中的页面资源
- 403: Forbidden, 被Web服务器拒绝了
- 404: URL找不到
- 500: Internal Server Error, 服务器错误
- 503: Server Unavailable, 服务器当前服务访问
http method and status code的更多相关文章
- 重定向Http status code 303 和 302
http 302 http 303 Http 302 302是一个普通的重定向代码.直观的看来是,请求者(浏览器或者模拟http请求)发起一个请求,然后服务端重定向到另一个地址.而事实上,服务端仅仅是 ...
- HTTP Status Code [RFC]
来源:http://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml Hypertext Transfer Prot ...
- Js 跨域CORS报错 Response for preflight has invalid HTTP status code 405
问题 公司项目H5调用接口遇到Response for preflight has invalid HTTP status code 405这样的错误,是使用PUT方式提交请求接口.Content-T ...
- [Jenkins][git]构建时提示Caused by: hudson.plugins.git.GitException: Command "/usr/bin/git reset --hard" returned status code 128:
--------------------- 如需转载,转载请注明出处. --------------------- 今日发现所有IOS构建相关的job全部失败,并提示如下错误: ERROR: Erro ...
- C# 移除Response Header,403调整返回为404Make IIS return a 404 status code instead of 403
Server Information Revealed For the benefit of those who land here through a google/bing search:: He ...
- HTTP 1.0 Status Code Definitions
part of Hypertext Transfer Protocol -- HTTP/1.1RFC 2616 Fielding, et al. 10 Status Code Definitions ...
- 500 status http status code 状态码
https://developer.mozilla.org/en-US/docs/Web/HTTP/Status Server error responses 500 Internal Server ...
- 转 Js 跨域CORS报错 Response for preflight has invalid HTTP status code 405
转自:http://www.cnblogs.com/SilenceTom/p/6697484.html 调用接口遇到Response for preflight has invalid HTTP st ...
- WCF REST开启Cors 解决 No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost' is therefore not allowed access. The response had HTTP status code 405.
现象: 编写了REST接口: [ServiceContract] public interface IService1 { [OperationContract] [WebInvoke(UriTemp ...
随机推荐
- EchartJS平均线、最大值、最小值
1.先来看一个没有平均线.最大值.最小值的简单实例 option = { title: { text: '未来一周气温变化', subtext: '纯属虚构' }, tooltip: { trigge ...
- (原创)团体程序设计天梯赛-练习集 L1-048 矩阵A乘以B (15 分)
给定两个矩阵A和B,要求你计算它们的乘积矩阵AB.需要注意的是,只有规模匹配的矩阵才可以相乘.即若A有Ra行.Ca列,B有Rb行.Cb列,则只有Ca与Rb相等时,两 ...
- java8 获取某天最大(23:59:59)和最小时间(00:00:00)
public class DateUtil { // 获得某天最大时间 2018-03-20 23:59:59 public static Date getEndOfDay(Date date) { ...
- 使用原生js来操作对象dom的class属性
之前一直都使用jquery来操作dom,今天想自己用原生写一些插件,却发现给dom增删class的时候,使用slice来截取className特别的麻烦,后来发现,原来原生JS本来就有提供api来对d ...
- CF431C k-Tree dp
Quite recently a creative student Lesha had a lecture on trees. After the lecture Lesha was inspired ...
- 我的web安全工程师学习之路——规划篇
据网上收集的web安全工程师需要掌握哪些技能,职位要求以及如何入门,加上学习网易推出的web安全工程师微专业课程,为了进一步学习,所以给自己做了一些小小规划,也希望给同样想成为web安全工程师的同仁们 ...
- C++的一种业务分发方案(另类的工厂模式)
在C++中,传统的业务分发.总要写一大串的switch-case,并且每次添加新业务时.都要在原有的switch-case里加一个分支,这就违反了设计模式中的开放封闭原则. 下面这样的方案,就全然去除 ...
- maven 过滤webapp下的文件
<plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-war-p ...
- apache 日志分割
Window apache 全局设置日志分割 apache [ httpd.conf ] 配置文件 开启日志模块:LoadModule log_config_module modules/mod ...
- P4173 残缺的字符串(FFT)
[Luogu4173] 题解 \(1.\)定义匹配函数 \(2.\)定义完全匹配函数 \(3.\)快速计算每一位的完全匹配函数值 #include<cstdio> #include< ...