Jquery ajax changes the contentType problem

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
clipboard.png

Mar.06,2021

ajax has a parameter that is ContentType. why write it in headers? if you write it in headers, you will fix the header information, and the document you are looking at is ContentType, instead of Content-Type.

Menu