I am attempting to use the Editor to allow users to enter text, hit a submit button and allow the entered text and formatting to be rendered as html on my page. I have used:
literal1.Text = Server.HtmlEncode(Editor1.Text)
And that causes the raw HTML to be displayed on my page, complete unformatted.
<ul> <li><span style="font-family: Arial; font-size: 24pt;">Item 1<br></span></li> <li><span style="font-family: Arial; font-size: 24pt;">Item 2<br></span></li> <li><span style="font-family: Arial; font-size: 24pt;">Item 3<br></span></li> </ul>
If I try:
literal1.Text = Editor1.Text
That causes the list <UL> to be rendered with bullets and font formatting, but it is all on one line like this (but with bullets in between each item):
|
What am I doing wrong? I cannot seem to find the right documentation to help me with this.
If you know where I can find it, I would be very grateful.
Thanks
Aaron