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

Modifying existing radeditor dialogs

1 Answer 57 Views
This is a migrated thread and some comments may be shown as answers.
Graham Berry
Top achievements
Rank 1
Graham Berry asked on 03 Aug 2010, 10:01 PM

I have read the article on "Disabling the Anchor tab on the Link Manager" and that seems straight forward but I want to add a new property, tracktag,  to the Hyperlink Manager tab - is this possible?

I have looked in the LinkManager.ascx and this seems fine and I can create a new field and label for my tracktag property but how do:
  1. Save the tracktag property in to an attribute in the created anchor link
  2. retrieve the value of the tracktag if its an existing anchor link

It really would be a pain if I had to create new customised dialogs for this purpose.

Also, is there any detailed information regarding radeditor extensions and they seem to be in snipets all over the place.



1 Answer, 1 is accepted

Sort by
Telerik team
answered on 05 Aug 2010, 05:33 PM
Hi Graham,

In order to achieve the required functionality you need to modify the several methods of the LinkManager prototype.
  1. The setupChildren() function initializes the input fields and comboxes inside the dialog. In this function you need to register the new property of the LinkManager object and assign it to the input field representing the custom attribute field, e.g.:
    HTML Markup
        <td class="reLabelCell">
            <label for="LinkTooltip" class="reDialogLabel">
                <span>CustomAttribute </span>
        <td class="reControlCell">
            <input type="text" id="CustomAttribute" />
    setupChildren function's body
    this.customAttribute = $get("CustomAttribute");
  2. To store the value entered in the custom input field you need to modify getModifiedLink() function. This is the method which creates or modify the link DOM element, e.g.:
    if (this.customAttribute.value.trim() == "")
        resultLink.setAttribute("CustomAttribute", this.customAttribute.value.trim());

  3. To populate the input field with the correct value (empty if it is a new link, or set the value of the CustomAttribute attribute of the selected link element) you need to modify the _cleanInputBoxes() and _loadLinkProperties().

For your convenience I have attached modified LinkManager.ascx file. The modifications that was made are wrapped with comments, e.g.:
//customAttribute --- END

I hope this helps.

Kind regards,
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Asked by
Graham Berry
Top achievements
Rank 1
Answers by
Telerik team
Share this question