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

radEditor stripping body onLoad() method

1 Answer 112 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Mike
Top achievements
Rank 1
Mike asked on 10 Oct 2014, 02:02 PM
I am trying to paste in the following code to the radEditor.  My company uses it for customers to design their own HTML pages.  Upon inserting the following code and saving it, the onLoad event is removed from the HTML.
<html>
<head></head>
<body onLoad="if (window.FormChanged){FormChanged()}">
 
</body>
</html>

What would cause this?  I have tried disabling all the filters with the EditorFilters.None option.  No dice.  I have disabled the ConvertToXhtml filter as well.  Still nothing.

Any help would be appreciated.

1 Answer, 1 is accepted

Sort by
0
Ianko
Telerik team
answered on 14 Oct 2014, 06:41 AM
Hi Mike,

The RadEditor do not have automatic logic that strips the onload attribute. Also, testing the same scenario on my end, I am unable to reproduce it. You can find attached a sample page which I have been using to follow the described situation. 

Are there any further details on the matter that could be relevant e.g., additional JS customizations or server-side filtering? The version with which I have been testing is 2014.2.724, let me know if you refer to an older one.

On a side note, with the upcoming Q3 2014 version, the RadEditor control will have a built-in filter that will strip all DOM attribute events. You should be aware that upon upgrading to this filter, the StripDomEventAttributes filter should be disabled. There will be more inforamiotn on the matter in the Content Filters article.

Regards,
Ianko
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Editor
Asked by
Mike
Top achievements
Rank 1
Answers by
Ianko
Telerik team
Share this question
or