protected void Page_Error(object sender, EventArgs e)
{
Exception ex = Server.GetLastError();
if (ex is HttpRequestValidationException)
{
Response.Write("请您输入合法字符串。");
Server.ClearError(); // 如果不ClearError()这个异常会继续传到Application_Error()。
}
}
从客户端..中检测到有潜在危险的 Request.Form 值。
最新推荐文章于 2019-04-16 09:47:23 发布