Click here to Skip to main content
15,888,461 members
Please Sign up or sign in to vote.
4.00/5 (2 votes)
See more:
i have a page that rquier to pass this code to the DB , but i wont becuase there is a validation on ASP.net that make an exception which is :
[HttpRequestValidationException (0x80004005): A potentially dangerous Request.Form value was detected from the client

so i tried to add in web.config the following
pages controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID" validateRequest="false"

thats not worked ,

also i tried to add this code on the same page :
<%@ Page Language="VB" Debug ="true" ValidateRequest="false" MasterPageFile="~/MasterPage.master" AutoEventWireup="false" CodeFile="AddNewPost.aspx.vb" Inherits="Default2" title="Untitled Page" %>

Also not worked

this page have a rich text editor , i need to pass HTML code to the DB

Please help

thanks a lot :)
Posted

 
Share this answer
 
Comments
Monjurul Habib 29-Apr-11 13:56pm    
my 5 for the links.
I found the answer
by Adding this in web.config
<system.web>
    <httpRuntime requestValidationMode="2.0" />
 
Share this answer
 
v2
Comments
Monjurul Habib 29-Apr-11 13:55pm    
Edited: code block.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900