i am displaying HTML i have saved in the DB but i am updating that so it will store encoded HTML. but i need to display proper HTML in inside a text field. but when ever i press the submit btn it tells me it does not like it. SAMPLE ERROR MESSAGE [SIZE="4"]A potentially dangerous Request.Form value was detected from the client (DisplayText="<b>Tertyer</b>"). [/SIZE]Description: Request Validation has detected a potentially dangerous client input value, and processing of the request has been aborted. This value may indicate an attempt to compromise the security of your application, such as a cross-site scripting attack. You can disable request validation by setting validateRequest=false in the Page directive or in the configuration section. However, it is strongly recommended that your application explicitly check all inputs in this case. Exception Details: System.Web.HttpRequestValidationException: A potentially dangerous Request.Form value was detected from the client (DisplayText="<b>Tertyer</b>"). Code (markup): I was wondering what i can do so that when i can encode b4 it gives me the error?
The best way how to go about that is to use FCKEditor. This is a nice text editor and works great. It is free to use and you just copy the code into you website directory and you can use it to. On the webpage you copy: <FCKeditorV2:FCKeditor ID="FCKeditor1" runat="server"> </FCKeditorV2:FCKeditor> And in the code behind you need to set the directory, set size and what all have to show in the toolbar If Not Page.IsPostBack Then FCKeditor1.BasePath = "~/fckeditor/" ' FCKeditor1.ToolbarSet = "Members" FCKeditor1.Width = 600 FCKeditor1.Height = 300 End If to access the info you just do FCKeditor1.value The website is www.fckeditor.net to download the code.