Completed
Last Updated: 18 Oct 2019 13:52 by ADMIN
Release R3 2019 SP1
Created by: Charles Liang
Comments: 0
Category: Editor
Type: Feature Request
0
Improve XSS filtering.
Completed
Last Updated: 02 Oct 2019 14:29 by ADMIN
Test the code below on iPhone and mobile chrome/safari and you'll get a JS error:

<script type="text/javascript">
    EditorCommandList = Telerik.Web.UI.Editor.CommandList;
    EditorCommandList["ApplySizeColor"] = function (commandName, editor, args) {
        if (editor.getSelectionHtml() != "") {
            editor.fire("FontSize", { value: "4" }); //fire the FontSize command
            editor.fire("ForeColor", { value: "red" });  //fire the ForeColor command
        }
        else {
            alert("Please, select some text!");
            args.set_cancel(true);
        }
    };
 </script>
<telerik:RadEditor ID="RadEditor1" runat="server" RenderMode="Auto" NewLineMode="Br" ContentAreaMode="Div" Height="500" Width="100%" Skin="Metro" _OnClientCommandExecuting="OnClientCommandExecuting">
    <HeaderTools>
        <telerik:EditorHeaderTool Name="ApplySizeColor" />
        <telerik:EditorHeaderTool Name="Redo" />
        <telerik:EditorHeaderTool Name="MobileEdit" Position="Right" />
        <telerik:EditorHeaderTool Name="ToggleScreenMode" Position="Right" />
    </HeaderTools>
    <Tools>
        <telerik:EditorToolGroup>
                <telerik:EditorTool Name="ApplySizeColor" Text="Apply Size and Color" ShowText="true"></telerik:EditorTool>
        </telerik:EditorToolGroup>
    </Tools>
</telerik:RadEditor>
Completed
Last Updated: 04 Sep 2019 16:00 by ADMIN
The problem appears to be related to the image and table resizing feature (introduced in Q3 2013), implemented for the Chrome browser. When the content has a large amount of nested tables with images, selecting an image is causing a slow operation and even an unexpected crash of the browser. 

With this example code you can disable the feature and resolve the performance issue:

<telerik:RadEditor ID="RadEditor1" runat="server">
</telerik:RadEditor>
<script type="text/javascript">
	Telerik.Web.UI.RadEditor.prototype._initializeResizableWidget =
		function myfunction() { };
</script>

Note that this line of code will disable the image/table resizing only for Chrome. Under Firefox and IE this feature is provided by the browser and will still be available.
Completed
Last Updated: 04 Sep 2019 15:57 by ADMIN
When you resize the RadEditor beyond the boundaries of the browser's viewport, absolute positioning will be applied to the control, which could result in problems with the layout in certain cases.

You can use the following workaround to fix the positioning of the editor until the problem is resolved. Just add the script below at the end of your page:

<script type="text/javascript">
                var onResizeStart = Telerik.Web.UI.RadEditor.prototype.onResizeStart;
                Telerik.Web.UI.RadEditor.prototype.onResizeStart = function() {
                                var editorWrapper = this.get_element();
                                this.resizeStartPosition = {
                                                position: editorWrapper.style.position,
                                                top: editorWrapper.style.top,
                                                left: editorWrapper.style.left
                                };
                                onResizeStart.call(this);
                }

                var onResizeEnd = Telerik.Web.UI.RadEditor.prototype.onResizeEnd;
                Telerik.Web.UI.RadEditor.prototype.onResizeEnd = function() {
                                var editorWrapper = this.get_element();
                                if (this.resizeStartPosition && this.resizeStartPosition.position != editorWrapper.style.position) {                                             
                                                $telerik.$(editorWrapper).css({
                                                                position: this.resizeStartPosition.position,
                                                                top: this.resizeStartPosition.top,
                                                                left: this.resizeStartPosition.left
                                                });
                                }
                                onResizeEnd.call(this);
                }
</script>
Completed
Last Updated: 04 Sep 2019 15:47 by ADMIN
Completed
Last Updated: 04 Sep 2019 15:47 by ADMIN
When an Image or a Table elements are being inserted into the content of the editor, the undo command should revert the insertion.
Completed
Last Updated: 04 Sep 2019 15:45 by ADMIN
When you copy a table from MS Excel and you paste it in the RadEditor under Chrome, an image that depicts the copied table will be inserted in the content area of the control along with the table.

You can use the following workaround to avoid inserting an image with the table:

        <telerik:RadEditor runat="server" ID="RadEditor1">
        </telerik:RadEditor>

        <script type="text/javascript">
            var getImages = Telerik.Web.UI.Editor.ClipboardImagesProvider.prototype.getImages;
            Telerik.Web.UI.Editor.ClipboardImagesProvider.prototype.getImages = function (event) {
                var images = getImages.call(this, event);
                debugger;
                if (event.clipboardData && images.length && event.clipboardData.getData("text/html")) {

                    return [];
                }

                return images;
            };
        </script>
Completed
Last Updated: 04 Sep 2019 15:44 by ADMIN
Inserting a table is causing the user to switch to HTML mode and insert manually a br element, so that he could start typing in the next line.

Possible solution is attaching this Client-side method on the OnClientCommandExecuted event of the RadEditor control:

<telerik:RadEditor runat="server" ID="RadEditor1"
    OnClientCommandExecuted="OnClientCommandExecuted"></telerik:RadEditor>


<script type="text/javascript">
    function OnClientCommandExecuted(editor, args) {
        var command = args.get_commandName();
        if (command = "InsertTable") {
            var selection = editor.getSelection();
            var range = selection.getRange();
            if (range.pasteHTML) {
                range.pasteHTML("<br />");
            }
            else {
                editor.pasteHtml("<br/>");
            }
        }
    }
</script>

The following workaround entirely changes the behavior by modifying the selection and selects the first TD

<telerik:RadEditor runat="server" ID="RadEditor1" OnClientPasteHtml="OnClientPasteHtml">
</telerik:RadEditor>

<script type="text/javascript">
    var identifierID = "RadEditor_AfterTable";

    function OnClientPasteHtml(editor, args) {
        var commandName = args.get_commandName();

        if (commandName === "InsertTable" || commandName === "TableWizard" ) {
            var currValue = args.get_value();
            currValue = currValue.replace(/<\/table>/gi, "</table><div id=" + identifierID + ">&#x200B;</div>");
            //currValue = currValue + "<div id=" + identifierID + ">&#x200B;</div>";
            
            args.set_value(currValue);
            setTimeout(function () {
                selectFirstTD(editor)
            }, 0);
        }
    }

    function selectFirstTD(editor) {
        var $ = $telerik.$;
        var contBody = editor.get_contentArea();
        var identifier = $(contBody).find("#" + identifierID);
        var table = identifier.prev();
        var elmToSelect = table.find("th")[0] || table.find("td")[0];

        if (elmToSelect.childNodes && !$telerik.isIE) {
            elmToSelect = elmToSelect.childNodes[0].nodeName === "#text" && elmToSelect.childNodes[0];
        }

        var hasNextElement = identifier.next()[0];
        
        while (hasNextElement && $(hasNextElement).is("style")) {
            hasNextElement = $(hasNextElement).next()[0];
        }
        
        editor.selectElement(elmToSelect);

        if (!hasNextElement) {
            table.after("<br/>");
        }

        identifier.remove();
    }
</script>
Completed
Last Updated: 04 Sep 2019 15:44 by ADMIN
The main issue is the inconsistent behavior of the borders around the content area.
Completed
Last Updated: 04 Sep 2019 15:44 by ADMIN
The initial problem is related with the JS error, because of which the editor's initialization is interrupted.  

You can workaround this by incorporating this piece of code:

<telerik:RadWindow ID="RadWindow1" runat="server" Width="805" Height="450" VisibleOnPageLoad="true">
	<ContentTemplate>
		<telerik:RadEditor runat="server" ID="RadEditor1" Height="200" Width="400" >
		</telerik:RadEditor>
	</ContentTemplate>
</telerik:RadWindow>

<script type="text/javascript">
	var oldCommand = Telerik.Web.UI.RadEditor.prototype.toggleEnhancedEdit;

	Telerik.Web.UI.RadEditor.prototype.toggleEnhancedEdit = function (newValue) {
		if ($telerik.isSafari && typeof (newValue) != "undefined" && false == this.disableContentAreaStylesheet(newValue)) {
			window.setTimeout(Function.createDelegate(this, function () {
				this.disableContentAreaStylesheet(newValue);
			}), 200);
		} else {
			oldCommand.call(this, newValue);

		}
	};
</script>
Completed
Last Updated: 04 Sep 2019 15:43 by ADMIN
If a list is created and every bullet is with different stylization. Stripping all formatting is causing the content to be inserted into one bullet and the styles are not correctly stripped. 
Completed
Last Updated: 04 Sep 2019 15:43 by ADMIN
When you add a symbol to the end of a line in IE, the cursor moves down to the next line.  This behavior does not exist in FF or Chrome, and it did not exist for IE in previous versions of the Editor.

Here is a video demonstrating the problem using the Telerik demo editor.

http://screencast.com/t/9S0TjfZzyFqj

Completed
Last Updated: 04 Sep 2019 15:20 by ADMIN
ADMIN
Created by: Slav
Comments: 1
Category: Editor
Type: Bug Report
0
When the Template Manager tool of RadEditor is enabled, the content of its dialog window is not loaded under IE.
Completed
Last Updated: 04 Sep 2019 15:18 by ADMIN
When an edited image is saved in the Editor's ImageManager, the file is selected but the preview/properties areas on the right are not active. The user should click first on another image and then come back to the edited one, in order to be able to preview it or to change its properties.
Video, demonstrating the behavior: http://screencast.com/t/DAtzhgalHvA
Completed
Last Updated: 04 Sep 2019 15:15 by ADMIN
1. Go to http:/demos.telerik.com/aspnet-ajax/editor/examples/overview/defaultcs.aspx
2. Choose the bullet list command from the toolbar and type some text
3. Choose the FormatCodeBlock command and insert some text
4. Press SHIFT+ENTER to insert <br>

Actual: If you continue pressing enter, new lines will not be inserted.
Expected: New lines are inserted.
Completed
Last Updated: 04 Sep 2019 15:14 by ADMIN
Under IE the get_text() retrieves only one word if there are many in the cells of a table.

This breaks the result of the RadEditorStatistics tool.
Completed
Last Updated: 04 Sep 2019 15:13 by ADMIN
When multiple instances of RadEditor are placed inside hidden ASP Panel (visible='false') which is ajaxified with RadAjaxManager/RadAjaxPanel, and then the visibility of the ASP Panel is switched to true, the Statistics Module of the second, third.. Editors display 'undefined'. The issue is observed under Internet Explorer.

The workaround is to use:

-either ASP:UpdatePanel instead of the RadAjaxManager/RadAjaxPanel

-OR use the following JavaScript override:

            Telerik.Web.UI.Editor.Modules.RadEditorStatistics.prototype.doCount = function () {
            
                if (!this.get_visible()) return;

                var content = this.get_editor().get_text();

                var words = 0;
                var chars = 0;
                if (content) {
                    var punctRegX = /[!\.?;,:&_\-\–\{\}\[\]\(\)~#'"]/g;
                    content = content.replace(punctRegX, "");
                    var trimRegX = /(^\s+)|(\s+$)/g;
                    content = content.replace(trimRegX, "");
                    if (content) {
                        var splitRegX = /\s+/;
                        var array = content.split(splitRegX);

                        words = array.length;

                        var newLines = /(\r\n)+/g;
                        content = content.replace(newLines, "");
                        chars = content.length;
                    }
                }

                var elem = this.get_element();
                elem.innerHTML = "<span style='line-height:22px'>" + "Words:" + " " + words + "   " + "Characters:" + " " + chars + " </span>";
            }

In order to make the above function override working, it must be placed:

-Either below the RadScriptManager and load all the necessary resources through ScriptReferences of the RadScriptManager (disable the embedded resources of the RadEditors' instances too)

-OR create an additional instance of RadEditor in a hidden div, outside the AjaxPanel and place the function override below it.

Completed
Last Updated: 04 Sep 2019 14:57 by ADMIN
When navigating inside a table in the RadEditor, pressing the right arrow key of the keyboard moves the cursor only till the last table cell and the cursor does not exits the table. 
Completed
Last Updated: 04 Sep 2019 14:24 by ADMIN
Release Q1 2014
The error is Sys.InvalidOperationException: Sys.InvalidOperationException: Component 'RadEditor1_dialogOpener' was not found.

When not enabled RadEditor should merely show its content, when Enabled is toggled to true it should render toolbars and add its functionality.

A possible workaround is using the Visible property instead and a div with runat=server as a placeholder for the editor while it is not rendered (its Content property will still return the HTML in it). Thus, the innerHTML server property of the div can be used to set the HTML from RadEditor in it.
Completed
Last Updated: 04 Sep 2019 14:22 by ADMIN
When I call OnParentNodeChanged on an Editor, while viewing the page using HTTPS, I get the following message in IE:
SEC7111: HTTPS security is compromised by (null) 
1 2 3 4 5 6