$.ajax({
type:'POST',
url:'',
data: JSON.stringify(data),
dataType:'json',
beforeSend:function(xhr) {
xhr.setRequestHeader("Content-Type","application/json");//此处设置header参数键值对
},
xhrFields: {
withCredentials:true
},
cache:false,
})
$.ajax({
type:'POST',
url:'',
data: JSON.stringify(data),
dataType:'json',
beforeSend:function(xhr) {
xhr.setRequestHeader("Content-Type","application/json");//此处设置header参数键值对
},
xhrFields: {
withCredentials:true
},
cache:false,
})