23 February 2011

ASP.NET - ValidateRequest and .NET Framework 4

When building a website in ASP.NET using the .NET Framework 4, ValidateRequest doesn't work as it used to anymore.

The solution lies in the Web.config, where you add:
<httpRuntime requestValidationMode="2.0" />
to the
<system.web>
section.

No comments:

Post a Comment