This is a migrated thread and some comments may be shown as answers.

Html tags stripped

1 Answer 87 Views
WebParts for SharePoint
This is a migrated thread and some comments may be shown as answers.
Eric
Top achievements
Rank 1
Eric asked on 31 Aug 2017, 12:12 PM

Hello,

we are using a RadEditor to save from content dynamically inserted into web pages.

 

Recently, some html tags inserted into the Html window of the RadEditor have started to be stripped (was working before). I have tried all options suggested around, and I finally found where the problem is coming from.

We upgraded our version of Word. Word now seems to have switched to html content, so some html code (<iframe> code) is now stripped away from the text.

 

This happens during the javascript call to OnClientSubmit :

    function OnClientSubmit(editor) {
        alert(editor.get_html()); // code is here
        editor.fire("FormatStripper", { value: "WORD" });
        alert(editor.get_html()); // code is not here anymore
    }

The code typed in the editor is this :

<b>Before Iframe</b>

<iframe src="http://alpedhuez.roundshot.com/3060/" scrolling="no" seamless="" webkitallowfullscreen="" mozallowfullscreen="" allowfullscreen="" width="640" height="360" frameborder="0"></iframe>

<b>After Iframe</b>

 

The first javascript alert gives this :

<b>Before Iframe</b>

<iframe src="http://alpedhuez.roundshot.com/3060/" scrolling="no" seamless="" webkitallowfullscreen="" mozallowfullscreen="" allowfullscreen="" width="640" height="360" frameborder="0"></iframe>

<b>After Iframe</b><br class="t-last-br">

 

The second alert, after the FormatStripped, gives this :

<b>Before Iframe</b>



<b>After Iframe</b><br class="t-last-br">

 

Is there a way so that the stripped does not remove html tags, and only REAL Word formating ?

I tried several FormatStripped options without success.

We cannot switch back to old Word versions, the editing window is used by several of our customers and we do not have control over their Word version.

 

Do you have any solution to make the stripper work properly (because I don't think the way it is working now is normal).

Regards and thanks

Eric

 

 

1 Answer, 1 is accepted

Sort by
0
Eric
Top achievements
Rank 1
answered on 31 Aug 2017, 12:23 PM

We are using

- Telerik.Web.UI version 2017.1.228.45

- Microsoft Office Professional Plus 2016 version 1707 (Build 8326.2076)

 

 

 

Tags
WebParts for SharePoint
Asked by
Eric
Top achievements
Rank 1
Answers by
Eric
Top achievements
Rank 1
Share this question
or