how to store and retrieve the HTML text Editor contents to SQL Server DB in ASP.net C#
asp.net, c#, html-editor, sql-server-2008-r2
Solution
You can use `HtmlEncode` & `HtmlDecode`:
// Encode the content for storing in Sql server.
string htmlEncoded = WebUtility.HtmlEncode(text);
// Decode the content for showing on Web page.
string original = WebUtility.HtmlDecode(htmlEncoded);
Problem
I am using a HMTL Text Editor in my asp.net with C# project. so, how do I store the editor contents in SQl Server 2008 DB so that it would be extracted as it is edited on the web page, means the same editing effects must be shown when I extract the data on a web page. please Help Thanks in Advance Nils