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

RadEditor problem when hyperlink contains >

1 Answer 33 Views
Editor
This is a migrated thread and some comments may be shown as answers.
margan
Top achievements
Rank 1
margan asked on 15 Sep 2016, 04:37 PM

Hi,

First the problem occurs in IE not in Firefox.

I have this string in html view: <a href="http://TEST?TestId=<%TEST_GUID%>">here</a>

In Firefox it looks like this:

HTML View: <a href="http://TEST?TestId=<%TEST_GUID%>">here</a>
Switch to design: here
Switch to HTML: <a href="http://TEST?TestId=<%TEST_GUID%>">here</a>

In IE 11

HTML View: <a href="http://TEST?TestId=<%TEST_GUID%>">here</a>
Switch to design: ">here
Switch to HTML: <a href="http://TEST?TestId=<%TEST_GUID% originalAttribute=" href"="" test?testid='<%TEST_GUID%"'>"&gt;here</a>

As you can see editing this in IE alway crashes the hyperlink.

Is there any way to fix this?

1 Answer, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 19 Sep 2016, 08:24 AM

Hi margan,

Such a value for the href attribute is invalid HTML and cannot be expected to work. Browsers attempt to fix it in different ways (for example, Firefox will encode the < and > symbols) and RadEditor also expects valid HTML strings, otherwise the commands and parsing logic may break.

What I can suggest is that you look into other ways to delimit the querystring values that are valid HTML. For example, you can replace the < and > symbols with an allowed symbol.

Regards,

Marin Bratanov
Telerik by Progress
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
Tags
Editor
Asked by
margan
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Share this question
or