I'm working on an angular js application. I have loaded jquery and I'm using some jquery methods in this application. My problem is $.ajax. It's working in Firefox and IE, but has problem in google chrome! Google chrome always shows Failed to load response data error in my ajax request. Even if I send ajax request manually with XMLHttpRequest()(without jquery), I still see this error message in the chrome console. I don't know what's the problem and how can I solve this. Everything is perfect in firefox, even IE, but chrome has problem! Here is my ajax code:
$.ajax({
url: "/testUrl",
type: "post",
dataType: "json",
contentType: "application/json; charset=utf-8",
headers: {
Accept: "application/json; charset=utf-8",
"Content-Type": "application/json; charset=utf-8"
}
}).success(function(data) {
});
Note, I have used jquery ajax request in a non angular js application before and everything is right in google chrome, but when I switched to angular, I saw this strange problem.