解决ASP.NET 4.0 "A potentially dangerous Request.Form value was detected from the client". 错误
2012-07-28 15:15
585 查看
在.net中,Request时出现有HTML或Javascript等字符串时,系统会认为是危险性值。立马报错。
(在.aspx文件头中加入这句: <%@ Page validateRequest="false" %>,但还是出现相同错误)
或是修改web.config文件:
<configuration>
< system.web>
<pages validateRequest="false" />
< /system.web>
< /configuration>
但错误依旧。
对.NET 4.0, 应该加上requestValidationMode="2.0" to the httpRuntime configuration section of the web.config :
<httpRuntime requestValidationMode="2.0"/>
结构:<configuration>
<system.web>
<httpRuntime requestValidationMode="2.0">
(在.aspx文件头中加入这句: <%@ Page validateRequest="false" %>,但还是出现相同错误)
或是修改web.config文件:
<configuration>
< system.web>
<pages validateRequest="false" />
< /system.web>
< /configuration>
但错误依旧。
对.NET 4.0, 应该加上requestValidationMode="2.0" to the httpRuntime configuration section of the web.config :
<httpRuntime requestValidationMode="2.0"/>
结构:<configuration>
<system.web>
<httpRuntime requestValidationMode="2.0">
相关文章推荐
- 错误解决:[A potentially dangerous Request.Form value was detected from the client (warning="卡Ć.
- discuz ASP.NET 4.0验证请求 A potentially dangerous Request.Form value was detected from the client
- 自己留存:小经验在asp.net 4.5或者asp.net mvc 5解决A potentially dangerous Request.Form value was detected from the client
- 错误解决:[A potentially dangerous Request.Form value was detected from the client (warning="卡Ć..."). ]
- 解决.Net 4.0 A potentially dangerous Request.Form value was detected from the client 异常
- 解决.Net 4.0 A potentially dangerous Request.Form value was detected from the client 异常
- A potentially dangerous Request.Form value was detected from the client (content1="<IMG border=0 src
- A potentially dangerous Request.Form value was detected from the client (txtTest="").
- 处理asp.net出现A potentially dangerous Request.Form value was detected from the client
- 出现错误‘A potentially dangerous Request.Form value was detected from the client’的解决方案
- A potentially dangerous Request.Form value was detected from the client (FCKeditor="<img alt="" src=
- 错误提示: A potentially dangerous Request.Form value was detected from the client ....
- Error:A potentially dangerous Request.Form value was detected from the (WebEditor1="...bsp; <B>
- MVC 请求参数中带有HTML会引发Validation异常 ("A potentially dangerous Request.Form value was detected from the client")
- .net 4.0 A potentially dangerous Request.Form value was detected from the client 的解决方案
- 【asp.net mvc】A potentially dangerous Request.Path value was detected from the client(检测到客户端有潜在危险的Request.Path值)
- 解决A potentially dangerous Request.Form value was detected from the client
- A potentially dangerous Request.Form value was detected from the client的解决办法
- A potentially dangerous Request.Form value was detected from the client(txtTest="<b>").
- A potentially dangerous Request.Form value was detected from the client 的解决方法