A potentially dangerous Request.Form value was detected from the client

If you get “A potentially dangerous Request.Form value was detected from the client” when you use Rich Text Editor or TextArea in your web projects. You can get this error if any html code is submitted from your form.

You can bypass this error with adding a parameter inside your asp.net aspx file

ValidateRequest=”false” inside <%@ Page element.

For example your page directive is

<%@ Page Language=”C#” AutoEventWireup=”true” CodeFile=”Default.aspx.cs” Inherits=”Test._Default” %>

Then you can use

<%@ Page Language=”C#” AutoEventWireup=”true” CodeFile=”Default.aspx.cs” Inherits=”Test._Default” ValidateRequest=”false” %> like that.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s