I use jquery ajax to send requests. When I make one request, the contentType of all subsequent requests will be fixed, and even if modified, it will be invalid
$.ajax({
url: url,
data: data,
type: "POST",
dataType: "json",
headers: {
"Content-Type": "application/json;charset=utf-8"
},
success: function (res) {
success(res);
},
error: function (data) {
error(data);
}
});
I think this is what the document says. Does it mean that ajax will always send the same contentType, to the server as long as it is requested once? is there a solution