要查看来自 AJAX 请求的错误消息,您可以执行以下操作:
$.ajax({ type:"POST", url:"http://mpdomain/WebService.asmx/Operation", data: "{'parameter1': '44906'}", contentType: "application/json;charset=utf-8", dataType: "json", success: function(data) { alert("success") }, error: function(ts) { alert(ts.responseText) } // or console.log(ts.responseText)});请注意,在error函数中,您将获得
responseText。



