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

[Solved] Changing Target Property - looks like a bug

2 Answers 77 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Joe
Top achievements
Rank 1
Joe asked on 08 Dec 2009, 06:00 AM

Hi!

This looks like a bug - try to add a link in Rad editor and set the Target property to open in  “Same Window”, link works fine (opens in new window).

Now when if you add another link to same page and set its Target property to any of the options, the Target property of previous link is set to “#” (which opens a new window).

 

Similarly on adding links to that page, sets the Target property of all previous links to “#” (Open in new window).

2 Answers, 1 is accepted

Sort by
0
Rumen
Telerik team
answered on 10 Dec 2009, 11:31 AM
Hi Joe,

Are you sure that the links with target="_self" inserted in RadEditor are opened when clicked in a new window? This is unexpected behavior and I was unable to reproduce it with this link <a href="http://www.telerik.com" target="_self">Telerik</a>.

I was unable to reproduce the # problem using the Save in External File example too. For your convenience I have attached my test video.

Are you able to reproduce the problem with the example? Please, also make sure that you use the latest version of RadEditor (Q3 SP1 2009).

Sincerely,
Rumen
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Joe
Top achievements
Rank 1
answered on 17 Dec 2009, 04:06 AM
Sorry, my bad!! Thanks... We had a bit of client side code that was doing the damage:

function OnClientLoad(editor, args)

       {

           var links = editor.get_document().getElementsByTagName("A");

           for (var i = 0; i < links.length; i++)

           {

               var link = links[i];

               link.setAttribute("target", "#");

           };

 

           var style = editor.get_contentArea().style;

           style.backgroundImage = "none";

           style.backgroundColor = "white";

          

        }

Tags
Editor
Asked by
Joe
Top achievements
Rank 1
Answers by
Rumen
Telerik team
Joe
Top achievements
Rank 1
Share this question
or