Click here to Skip to main content
15,038,237 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
When,
C#
ValidateRequest="true"

Getting Error :
A potentially dangerous Request.Form value was detected from the client (ctl00$ContentPlaceHolder1$ckDescription="

Error Possibilities : HTML tags in Ckeditor.

When,
C#
ValidateRequest="false"

Getting Error :
Invalid postback or callback argument. Event validation is enabled using <pages enableeventvalidation="true"> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.

Error Possibilities : Filling Listboxs dynamically
Posted
Updated 8-Apr-15 23:42pm
v3
Comments
[no name] 9-Apr-15 6:08am
   
Check my solution,in your page directive u can put this code <%@ Page ValidateRequest="false" %>.change ValidateRequest="True" to ValidateRequest="False"

XML
<%@ Page EnableEventValidation="true" <pre lang="xml">ValidateRequest="false" %&gt;


&lt;pre lang=&quot;xml&quot;&gt;&amp;lt;system.web&amp;gt;
   &amp;lt;pages enableEventValidation=&amp;quot;false&amp;quot;/&amp;gt;
&amp;lt;/system.web&amp;gt;&lt;/pre&gt;</pre>
   
v2
Comments
[no name] 9-Apr-15 6:09am
   
In your solution,there have some unusual tags.pls check and update it.
Kamal Surani 9-Apr-15 9:30am
   
some blog special tag so can get error but you handled error
Write like this in your page..

ASP.NET
<%@ Page ValidateRequest="false" %>


Ref this link : A potentially dangerous Request.Form value was detected from the client
   
v2
VB
<%@ Page Title="" Language="C#" MasterPageFile="~/MstrNew.Master" AutoEventWireup="true"
    CodeBehind="frmCreateBlog.aspx.cs" Inherits="frmCreateBlog"
    ValidateRequest="true" EnableEventValidation="true" %>

Problem Solved Using
VB
ValidateRequest="false" EnableEventValidation="true"
   
v2

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