We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Remove all default HTNL tags except content of <body>

Thread ID:

Created:

Updated:

Platform:

Replies:

132850 Sep 25,2017 01:43 PM UTC Sep 28,2017 04:06 AM UTC ASP.NET Core 3
loading
Tags: RichTextbox
JP Gutton
Asked On September 25, 2017 01:43 PM UTC

Hi,

Is there a way with RTE to remove all the HTML tags of the document except the content of <body>, ie when I see the HTML content of the text it gives me <html>, <head> etc. with a lot of stuff inside, I only want to pass the content of body to the controller.

Also it is possible to have the character count include the HTML parts instead of just the "View" part, as I have limitation on the size of the field ?

Thank you,

Keerthana Rajendran [Syncfusion]
Replied On September 26, 2017 01:06 PM UTC

Hi JP Gutton, 
 
Thank you for using contacting Syncfusion support. 
 
Query 1: Is there a way with RTE to remove all the HTML tags of the document except the content of <body>, ie when I see the HTML content of the text it gives me <html>, <head> etc. with a lot of stuff inside, I only want to pass the content of body to the controller. 
 
To pass the content of RTE we suggest you to use getText() method which will return the content of RTE. Please refer to the below given code 
 
function gettext() 
    { 
        var obj = $("#RteSample").data("ejRTE"); 
        alert(obj.getText()); 
 
    } 
 
We have attached a sample for reference. Please download the sample from 
 
 
Query 2: Also it is possible to have the character count include the HTML parts instead of just the "View" part, as I have limitation on the size of the field ? 
 
Characters count will be based on the number of characters present inside editor and HTML parts cannot be included in this count. 
 
Regards, 
Keerthana 


JP Gutton
Replied On September 27, 2017 02:33 PM UTC

Thank you for your answer !


Keerthana Rajendran [Syncfusion]
Replied On September 28, 2017 04:06 AM UTC

Hi JP Gutton, 
 
Thanks for your update. Please get back to us if you require further assistance on this. We will be happy to assist you 
 
Regards, 
Keerthana. 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;