Radeditor changing formatting/styles.

2 posts, 0 answers
  1. Brad
    Brad avatar
    35 posts
    Member since:
    Feb 2006

    Posted 28 Mar 2012 Link to this post

    In the application there is a editresults page where the radeditor is being used. The results data is copied from a word document and pasted into the radeditor. The data that is saved is show on a front end website and the styling was exact to what was on the editor. The application was originally built under telerik version under 2011.1.519.35. This year the application was updated to version 2012.1215.35. Now the data looks different. When I pasted the data from the word document into the editor the formatting seemed to be fine but when checking the data on the front end site it would appear the styling is different. As a test I copied the data that was formatted with the previous version of telerik and pasted into a word document saved it and copied that data into the radeditor and the styling still changes. Has the rad editor changed on how it would paste the data?
  2. Rumen
    Rumen avatar
    14462 posts

    Posted 02 Apr 2012 Link to this post


    The only change that I am aware of is that RadEditor strips style="MARGIN: 0in 0in 0pt" attributes in the P tags. To avoid this behavior overwrite the following two functions and put them under the RadEditor's declaration:
    Copy Code
    <telerik:RadEditor runat="server" ContentFilters="None" ID="RadEditor1">
    <Content><P style="MARGIN: 0in 0in 0pt">Some more new text<o:p></o:p></P></Content>
    <script type="text/javascript">
    Telerik.Web.UI.RadEditor.prototype._markExistingEmptyParagraphs = function(content) {
      return content;
    Telerik.Web.UI.RadEditor.prototype._fixBrokenParagraphs = function(content) {
      return content;

    You can also disable the OptimizeSpan filter as well as test by disabling other built-in content filters in the Built-in Content Filters demo.

    If the problem still persists, please provide sample content and detailed steps with screenshots or video demonstrating how to reproduce the problem.

    All the best,
    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.
Back to Top