asp.net获取json datetime 会是一个很纠结的格式 下面是格式好的方法 纯属笔记 希望也大家有帮助
$.ajax({
type: "POST",url: "/Notify.mvc/Get",
data: "",
contentType: "application/json; charset=utf-8",
dataType: "json",
dataFilter: function(data, type) {
return data.replace(/"\\\/(Date\([0-9-]+\))\\\/"/gi, 'new $1');
},
success: function(n) {
if (n != "False") {
$("#notify").text(decodeURI(n.NotifyTopic));
}
}
}
);