SetTextToXHTML()

Last post 06-20-2010, 7:42 PM by jonathanexact. 2 replies.
Sort Posts: Previous Next
  •  06-18-2010, 2:35 AM 61859

    SetTextToXHTML()

    Hi,
     
    I have a few documents that, when they are loaded into the editor, will trigger the 'script is not responding' message in Firefox & Chrome (but not IE). Further analysis points to the (very extensive) usage of Microsoft Word tags in these documents, like mso-bidi-font-family, mso-fareast-font-family, etc.
     
    I found that SetTextToXHTML() will remove these tags, but I want to know what else the function does, as I don't want to lose information from these documents when they are saved. 
     
    Can anyone help me? Thanks!
  •  06-18-2010, 10:19 AM 61865 in reply to 61859

    Re: SetTextToXHTML()

    You can teach your end users use the Clean Up HTML button (Clean Up HTML) in Cute Editor to remove extraneous tags and streamline your HTML code.

    But it's easy to make mistakes if your end users forget Clean Up HTML before saving the content into database.

    Cute Editor provides two server side methods which can fix these mistakes automatically and tidy up sloppy editing into nicely layed out markup.

    You can use Editor.CleanUpHTMLCode method to remove empty tags, combine nested FONT tags, and otherwise improve messy or unreadable HTML code.

    You can aslo Editor.CleanUpMicrosoftWordHTML method to remove the extraneous HTML code generated by Microsoft Word.
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  06-20-2010, 7:42 PM 61883 in reply to 61865

    Re: SetTextToXHTML()

    Hi Adam,
     
    I understand that (and will definitely educate the end users to generate clean HTML), but I have a some existing documents with these tags in the database, and I'm thinking of cleaning them up before loading their contents into the editor. This is because loading the documents as they are will crash the editor in Firefox & Chrome (not IE though). 
     
    I had wanted to know what the function SetTextToXHTML() does, so that I won't inadvertently remove actual content from these documents.
     
    Thanks!
View as RSS news feed in XML