【发布时间】:2012-11-30 18:47:35
【问题描述】:
在我的 $.ajax 中有
error: function (xhr, ajaxOptions, thrownError) {
var result = $.parseJSON(xhr.responseText);
alert(result.ErrorMessage);
}
尽管这对我以前的所有应用程序都有效,但这一次却让我窒息并给了我一个无效的 JSON 错误。我正在使用 jQuery 1.5,asp.net MVC 3。
PS:我查看了jQuery documentation,但没有看到error 使用的JSON 的示例。
【问题讨论】:
标签: asp.net-mvc json asp.net-mvc-3 jquery