contentType: "application/json",
data:{
"name":"yo yo" //默认添加额外参数
},
headers: { // 默认添加请求头...,
} ,
error: function(jqXHR, textStatus, errorMsg){ // 出错时默认的处理函数
// jqXHR 是经过jQuery...$.ajaxSetup( {
headers: { // 默认添加请求头
"Authorization": "Bearer xxxxtokenxxx" ,
}...,
error: function(jqXHR, textStatus, errorMsg){ // 出错时默认的处理函数
// jqXHR 是经过jQuery封装的XMLHttpRequest...537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36
Content-Type: application/json
Accept: */*
X-Requested-With