mohammad reza
mohammad reza

Reputation: 3442

Use ckeditor for enter Message in ASP.net and LINQ to SQL

I want to use Ckeditor for Entering text and I want to save that text in Database,but when I Write the text in editor and I want to save it in database this error appeared .

A potentially dangerous Request.Form value was detected from the client (editor1="

this is my code :

M.Body = editor1.Value;

my feild that I want to save the text is Body and I use LINQ to SQL for relation with database .

How do I can save text in database whit this editor ?

Upvotes: 0

Views: 2498

Answers (1)

Marek Karbarz
Marek Karbarz

Reputation: 29304

try encoding your CKEditor HTML output. Add this to your CKEditor declaration:

oCKeditor.Config['HtmlEncodeOutput'] = true;

More information about the error you're getting on ASP.NET Website

Upvotes: 2

Related Questions