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

RadEditor - Duplicated Images

5 Answers 96 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Peter Hyde
Top achievements
Rank 1
Peter Hyde asked on 19 Dec 2014, 08:28 PM
I am working on a system that uses a RadEditor control to setup content for mailings. I recently had a user notify me that their email went out with a single image duplicated 4 extra times at the bottom of the email. If I look at the email, I do see the duplicated image. If I look at the editor control in design view I do not see the images. Looking at the HTML view of the editor, I do see the extra images. All copies appear to be in divs with the class "telerik_paste_container", and these are contained within a parent div whose id is "radePasteHelper". I'd imagine that radePasteHelper and its children are used behind the scenes by the control to aid in pasting operations, but that they probably shouldn't end up in the content of the editor. 

I am told the user did some cut/paste with the image in question (not copy/paste, cut/paste), and this is a pretty savvy user so I'd wager they are stating the facts accurately. This user uses chrome for her work. We have another power user that uses IE and has never seen this bug on her mailings. 

This isn't the first time we've seen this, though it's my first time posting on the forums. I am personally not able to recreate in either Chrome or FireFox, and the user in question can't make it happen every time either. I'd like to know what's causing the duplicated images, and if possible see a workaround or a fix for the issue. If you'd like me to post a copy of the bad mailing or if you'd like any other information please let me know, I'll be happy to provide. Thanks.

Telerik.Web.UI ver 2014.2.724.40

5 Answers, 1 is accepted

Sort by
0
Stanimir
Telerik team
answered on 23 Dec 2014, 02:49 PM
Hello,

I tested the issue, but I was not able to reproduce it.

Could you provide me with the declaration of the RadEditor control? Also is there something special in the configuration? Is the ContentAreaMode property set to Div or Iframe? Are there any custom content filters enabled?

Once I review the provided information, I will be able to advice you further.


Regards,
Stanimir
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Peter Hyde
Top achievements
Rank 1
answered on 24 Dec 2014, 05:52 PM
Here is the declaration:

            <telerik:RadEditor ID="editContentHTML" runat="server" EditModes="Design, Html" ToolsFile="~/StandardToolsFile.xml" 
                EnableResize="False" ContentFilters="MakeUrlsAbsolute, DefaultFilters, ConvertInlineStylesToAttributes" AutoResizeHeight="false" OnClientCommandExecuted="OnClientCommandExecuted">
            </telerik:RadEditor>

I've also included the content of the tools file below just in case this information is helpful:
<root>
<modules>
    <module name="RadEditorStatistics" dockable="false" dockingZone="Bottom" enabled="true" visible="true"/>

</modules>
<tools name="MainToolbar" enabled="true">
<tool name="AjaxSpellCheck"/>
    <tool separator="true"/>
    <tool name="Cut" />
    <tool name="Copy" />
    <tool name="Paste" shortcut="CTRL+!"/>
    <tool separator="true"/>
    <tool name="PasteFromWord" />
    <tool name="PasteFromWordNoFontsNoSizes" />
    <tool name="PastePlainText" />
    <tool name="FormatStripper" />
    <tool separator="true"/>
<tool name="Undo" shortcut="CTRL+Z"/>
<tool name="Redo" shortcut="CTRL+Y"/>
<tool separator="true"/>
<tool name="InsertSymbol" />
<tool name="InsertParagraph" />
<tool name="InsertHorizontalRule" />
<tool name="InsertDate" />
<tool name="InsertTime" />
    <tool separator="true"/>
    <tool name="InsertLink" />
    <tool name="Unlink" />
<tool name="LinkManager" shortcut="CTRL+K"/>
<tool name="ImageManager" shortcut="CTRL+G"/>
    <tool name="InsertTable" />
    <tool name="StyleBuilder" />
    <tool separator="true"/>
    <tool name="Help" />
</tools>
<tools dockable="false"  enabled="true">
<tool name="ForeColor" />
<tool name="BackColor"></tool>
<tool name="FontName"></tool>
    <tool separator="true"/>
<tool name="FontSize"></tool>
    <tool separator="true"/>
    <tool name="Bold" shortcut="CTRL+B"/>
<tool name="Italic" shortcut="CTRL+I"/>
<tool name="Underline" shortcut="CTRL+U"/>
<tool name="Superscript" />
<tool name="Subscript" />
<tool separator="true"/>
<tool name="InsertOrderedList" />
<tool name="InsertUnorderedList" />
<tool name="Indent" />
<tool name="Outdent" />
<tool separator="true"/>
    <tool name="JustifyLeft" />
    <tool name="JustifyCenter" />
    <tool name="JustifyRight" />
    <tool name="JustifyFull" />
    <tool name="JustifyNone" />
    <tool separator="true"/>
    <tool name="InsertSnippet" />
  </tools>
<symbols></symbols>
<fontNames> </fontNames>
<fontSizes></fontSizes>
<colors></colors>
</root>

ContentAreaMode: IFrame

Please let me know if I can provide any further information to assist in troubleshooting, and I hope you have a great holiday!
0
Ianko
Telerik team
answered on 26 Dec 2014, 09:50 AM
Hello Peter,

Thank you for further cooperating on the matter.

The described issue really sounds like a bug, although even with the configuration provided it is not reproducible locally. Could you also verify if the OnClientCommandExecuted handler implements logic that might lead to this side effect? Also, you can try removing the ContentFilters property, so to reset it to its default collection.

If the problem is not from the logic implemented in the handler, then I suggest prompting the users for exact steps to reproduce, so that we could be able to debug the pasting functionality and locate the exact origin of the problem.

Regards,
Ianko
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Peter Hyde
Top achievements
Rank 1
answered on 29 Dec 2014, 05:32 PM
OnClientCommandExecuted looks pretty innocuous. I've pasted it at the bottom of this reply.

I'll see if I can get the user to recreate the problem in our test environment. If she can do that reliably then I'll make the change to ContentFilters that you suggested, see if the problem goes away.

        // Fixes Insert Snippet Issue 
        function OnClientCommandExecuted(editor) {
            var tool = editor.getToolByName("InsertSnippet");
            //Disable header update functionality  
            tool.set_updateHeader(false);
          }

0
Ianko
Telerik team
answered on 05 Jan 2015, 08:17 AM
Hello Peter,

Indeed, the provided code snippet is not the source of the issue.

Let us know when further details about the recreation steps are available, so that we could be able to properly examine the problem.

Regards,
Ianko
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Editor
Asked by
Peter Hyde
Top achievements
Rank 1
Answers by
Stanimir
Telerik team
Peter Hyde
Top achievements
Rank 1
Ianko
Telerik team
Share this question
or