666

")中检测到有潜在危险的 Request.Form 值。" /> 666

")中检测到有潜在危险的 Request.Form 值。 - 秒客网" />

从客户端(Content="

666

")中检测到有潜在危险的 Request.Form 值。

时间:2023-03-09 00:50:33
从客户端(Content="<p>666</p>")中检测到有潜在危险的 Request.Form 值。

出现:从客户端(Content="<p>测试</p>")中检测到有潜在危险的 Request.Form 值。

一般是在线编辑器有HTML标签的,我是用的MVC.

所以,首先:在action上加[ValidateInput(false)]标识

[HttpPost]
[ValidateInput(false)]
public ActionResult Add(User user)
{
return View();
}

然后:在httpRuntime  节点上加设置

<system.web >
<httpRuntime  requestValidationMode="2.0"  maxRequestLength="10240" executionTimeout="60"   />
</system.web >

行了。