asp.net C# display ajax html editor contents

Codeaddict7423
Codeaddict7423 used Ask the Experts™
on
Hello,

I am attempting to implement a form containing an HTML editor where users can input group messages.  The HTML editor writes this content to a database table.

Now, I'm trying to display this content (with formatting such as <span style="color:#ff0000;"> NEWS</span> ) so that it shows up in a separate page like a modal popup.

Any help would be greatly appreciated.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Manoj PatilSr. Software Engineer
Commented:
Just put some piece of code to understand better.

Author

Commented:
techChallenger1,

Thank you for the quick reply. Below, please find a string of html-formatted text written to the database table:
----------
test 09 <span style="color: #ffffff; background-color: #33ff00;">blue warning</span>

-------
 My goal is to display this on a control that can interpret the formatted text to show up on a pop-up page.
Manoj PatilSr. Software Engineer

Commented:
The problem may be occur by double quote.
Try with replacing double quote by single and let me know.
Roopesh ReddyIT Analyst
Top Expert 2012

Commented:
Hi,

Which HTML editor are using?

Did you tried this - http://htmleditor.codeplex.com/

Hope it helps u...
hi, I did not understant very well what you are trying to achieve. Still, from the contents of your post I feel you might be looking for a way to get you editor to interprete the HTML you got from a DB.

If this is the case the editor might have a differente property for insert the desired input, I've had experiences with editors that when ypu want to insert HTML you cannot use the .Text, there is actually a property named .Html, or even on some cases there is a bool property like IsContentHtml our isHtml

On another aproach if you are looking for a asp control where you can insert Text containing html tags and you want it to be interpreted when the page loads, insert the text into a asp:literal
for example :
 
<asp:Literal runat="server" Text="<h1> THIS IS A TESTE </h1>"></asp:Literal> 

Open in new window

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial