public ActionResult test()
{
Response.StatusCode = (int)HttpStatusCode.InternalServerError;
var result = new JsonResult();
result.Data = new { message = "系统发生错误" };
result.JsonRequestBehavior = JsonRequestBehavior.AllowGet;
return result;
}
服务器结果是:
本地结果是: