我在下面的
WebMethod
中设置了一个断点,但我从未触发断点。
cs:[WebMethod]
public static string search()
{
return "worked";
}
aspx:
function search() {
$.ajax({
type: "POST",
url: "ProcessAudit/req_brws.aspx/search",
data: "{}",
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function (msg) {
alert(msg)
}
});
}
<button id = "btnSearch" onclick = "search()" >Search</button>
Failed to load resource: the server responded with a status of 500 (Internal Server Error)
。 - Si8