|
Rank: Advanced Member Groups: Member
Joined: 11/13/2008 Posts: 43
|
Hi, I'm using the eo:Editor control, and I'm trying to completely clear its Html when the page loads. I've tried the following in the Page_Load event:
Code: C#
Editor1.Html = String.Empty;
but it still always contains <p> </p> How can I remove this HTML?
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi,
This behavior is by design. Unlike a traditional text editor, the browser would not display the cursor if its content is really empty. So it is necessary to modify substitute empty string with "<p> </p>". As a result, you will need to manually check whether it is "<p> </p>" and then regard it as empty in your code if needed.
Thanks!
|
|
Rank: Advanced Member Groups: Member
Joined: 11/13/2008 Posts: 43
|
OK, I understand.
Is there a setting somewhere where I can turn of the final \n character? The default Html property is actually "<p> </p>\n"
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
No. You will need to handle that yourself.
Thanks
|
|