Ajax请求的一个重要属性contentType

比如

contentType : 'application/json;charset=UTF-8',

或者

contentType : 'text/html;charset=UTF-8',

如果不加此参数,会出现不可预知的错误!

比如某些加了安全控件的系统,不加此参数,会直接报错403,系统认为你的此次请求是在攻击系统。

原文地址:https://www.cnblogs.com/whoknows1/p/9555004.html