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

Link Manager in Firefox 3.6.x

5 Answers 32 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Clint MacDonald
Top achievements
Rank 2
Clint MacDonald asked on 20 Mar 2012, 05:11 PM
Hello,
I have a weird situation that I have racked my brains over and searched the web a lot and can not find an answer. I have the latest telerik RadEditor (2012.1.215.35) in a website and everything works as expected in IE, Google and Safari.  It also works fine in Firefox 11.  However, in firefox 3.6.x I have found that the link manager does not work fully!  And on two different servers it acts differently.

Here is what I did!

Created the editor page and copied it to our development server environment and everything seems to work fine.
- Copied the dll,s in the bin folder and the editor page to the production server and the unexpected behaviour occurs.

The Unexpected behaviour.
- when using the link manager the link is not actually created (only observed in firefox 3.6.x)
- If I highlight some text, click link manager, enter appropriate info and click "OK", nothing happens, the dialog closes, but no link is created.
- If I highlight an image, use the link manager, it works properly as expected????
- It works fine on the development server

Weird....
I have setup a test page on the production server so that you can see the behaviour yourself....need firefox 3.6.x
http://ugradcalendar2.uwaterloo.ca/gcms/page_version_editor.aspx

Thanks
Clint

5 Answers, 1 is accepted

Sort by
0
Dobromir
Telerik team
answered on 23 Mar 2012, 11:10 AM
Hi Clint,

I already answered your support ticket on the subject. For convenience I will paste my answer here as well.

Thank you for bringing this problem to our attention. I have logged it into our database and we will do our best to have it fixed for one of the upcoming releases.

For the time being, you can use the following JavaScript to avoid this problem:

Telerik.Web.UI.Editor.AlignCommand.prototype.getState = function (oWindow)
{
    oWindow = oWindow || this.get_window();
    var doc = oWindow.document;
  
    if ($telerik.isFirefox) {
        var alignDirection = this.get_alignment();
        var selection = doc.getSelection();
        if (selection && selection.getRangeAt) {
            var selectedElement = selection.getRangeAt(0).commonAncestorContainer;
            var blockElement = this.utils.getFirstBlockElementUp(selectedElement);
  
            state = blockElement && blockElement.style.textAlign == alignDirection;
        }
        else
            state = false;
  
        return state ? Telerik.Web.UI.Editor.CommandStates.On : Telerik.Web.UI.Editor.CommandStates.Off;
    }
    else
        return $T.Editor.AlignCommand.callBaseMethod(this, "getState", [oWindow]);
}


Regards,
Dobromir
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Clint MacDonald
Top achievements
Rank 2
answered on 30 Mar 2012, 04:38 PM
Thank-you for the work around, it does fix the link manager to work as expected!  HOWEVER, there is a major issue with the script in ALL browsers. 

If you go to HTML view and back to design view, a lot of the buttons are disabled!  and in fact the buttons at the button still have the HTML view as the highlighted one!

I am not familiar with how this script interacts with the editor and would be spinning my wheels trying to find what is causing this!

I will reply in the forum so that others are not mislead in providing this as a solution

Any other suggestions or updates to the script provided?

Clint
0
Dobromir
Telerik team
answered on 02 Apr 2012, 09:51 AM
Hi Clint,

The described behavior might occur in case of a JavaScript error.

Could you try to change the last line of the script:
return $T.Editor.AlignCommand.callBaseMethod(this, "getState", [oWindow]);

with the following one:
return Telerik.Web.UI.Editor.AlignCommand.callBaseMethod(this, "getState", [oWindow]);

and see if the problem still occurs? The variable $T is an alias of Telerik.Web.UI namespace used in the RadEditor's script and if you do not have it declared on the page a JavaScript error will be thrown.

Regards,
Dobromir
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Clint MacDonald
Top achievements
Rank 2
answered on 10 Apr 2012, 02:09 PM
This worked fantastically,
Thank-you very much
0
Dobromir
Telerik team
answered on 11 Apr 2012, 11:36 AM
Hi Clint,

I am writing to notify you that later today we are about to release a service pack of RadControls for ASP.NET AJAX where this issue has been fixed.

Regards,
Dobromir
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Editor
Asked by
Clint MacDonald
Top achievements
Rank 2
Answers by
Dobromir
Telerik team
Clint MacDonald
Top achievements
Rank 2
Share this question
or