验证请求=“假"在 Asp.Net 4 中不起作用 [英] ValidateRequest="false" doesn't work in Asp.Net 4
本文介绍了验证请求=“假"在 Asp.Net 4 中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个使用 ckeditor 的表单.这种形式在 Asp.Net 2.0 和 3.5 上运行良好,但现在在 Asp.Net 4+ 中不起作用.我有 ValidateRequest="false" 指令.有什么建议吗?
I have a form at which I use ckeditor. This form worked fine at Asp.Net 2.0 and 3.5 but now it doesn't work in Asp.Net 4+. I have ValidateRequest="false" directive. Any suggestions?
推荐答案
在错误页面本身找到了解决方案.只需要添加 requestValidationMode="2.0";在 web.config 中
Found solution on the error page itself. Just needed to add requestValidationMode="2.0" in web.config
<system.web>
<compilation debug="true" targetFramework="4.0" />
<httpRuntime requestValidationMode="2.0" />
</system.web>
MSDN 信息:HttpRuntimeSection.RequestValidationMode 属性
这篇关于验证请求=“假"在 Asp.Net 4 中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文