Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#10531 closed Bug (invalid)

Problems with 4.1.2 release

Reported by: Dennis Plotzke Owned by:
Priority: Normal Milestone:
Component: General Version:
Keywords: Cc:

Description

Hi,

We are experiencing the following new issues with the 4.1.2 release:

1) setData with html formatted text no longer works for having the editor start off with an Alpha list (see snippet below).

CKEditor.setData('<ol start="1" style="list-style-type: upper-alpha;"><li></ol>');

2) setData with html data no longer utilizes the styles contained in the html (see attachment for html that is used in setData() call. The headers for the pre-formatted table should be light blue, but are appearing without styling. See the included codeblock at the bottom of this issue which is used in the setData() call.

3) The content menu no longer shows "Numbered List Properties" in the dropdown.

Dennis

<style type="text/css">
    .hwhlTable {
        width: 100%;
    }

    .hwhlHeaderRow {
         width: initial;
         border: solid windowtext 1.0pt; 
         border-left: none; 
         background: #E5EFF2; 
         padding: 0in 5.4pt 0in 5.4pt; 
         height: 47.85pt;
    }

    .hwklRow {
         width: 149.5pt;
         border-top: none; 
         border-left: none; 
         border-bottom: solid windowtext 1.0pt; 
         border-right: solid windowtext 1.0pt; 
         padding: 0in 5.4pt 0in 5.4pt; 
         vertical-align:middle;
    }

    .MsoNormal {
    }
    
</style>
<table class="hwhlTable" border="1" cellspacing="0" cellpadding="0" width="100%"
    style='width: 100%; border-collapse: collapse; border: none;'>
    <tr style='height: 47.85pt'>
        <td width="25%" valign="top" style='width: 1.7in; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; background: #E5EFF2; padding: 0in 5.4pt 0in 5.4pt; height: 47.85pt'>
            <p class="MsoNormal" align="center" style='margin-bottom: 0in; margin-bottom: .0001pt; text-align: center; line-height: normal'>
                What do you know?
            </p>
        </td>
        <td width="25%" valign="top" class="hwhlHeaderRow">
            <p class="MsoNormal" align="center" style='margin-bottom: 0in; margin-bottom: .0001pt; text-align: center; line-height: normal'>
                What do you want to know?
            </p>
        </td>
        <td width="25%" valign="top" class="hwhlHeaderRow">
            <p class="MsoNormal" align="center" style='margin-bottom: 0in; margin-bottom: .0001pt; text-align: center; line-height: normal'>
                How will you learn?
            </p>
        </td>
        <td width="25%" valign="top" class="hwhlHeaderRow">
            <p class="MsoNormal" align="center" style='margin-bottom: 0in; margin-bottom: .0001pt; text-align: center; line-height: normal'>
                What have you learned?
            </p>
        </td>
    </tr>
    <tr>
        <td valign="top" class="hwklRow" style='border: solid windowtext 1.0pt;'>
            <p class="MsoNormal" style='margin-bottom: 0in; margin-bottom: .0001pt; line-height: normal'>
            </p>
        </td>
        <td valign="top" class="hwklRow">
            <p class="MsoNormal" style='margin-bottom: 0in; margin-bottom: .0001pt; line-height: normal'>
            </p>
        </td>
        <td valign="top" class="hwklRow">
            <p class="MsoNormal" style='margin-bottom: 0in; margin-bottom: .0001pt; line-height: normal'>
            </p>
        </td>
        <td valign="top" class="hwklRow">
            <p class="MsoNormal" style='margin-bottom: 0in; margin-bottom: .0001pt; line-height: normal'>
            </p>
        </td>
    </tr>
</table>

Attachments (1)

kwhl_template.html (2.8 KB) - added by Dennis Plotzke 6 years ago.
Html file that is used with setData call that doesn't utilize styling in latest 4.1.2 release.

Download all attachments as: .zip

Change History (5)

Changed 6 years ago by Dennis Plotzke

Attachment: kwhl_template.html added

Html file that is used with setData call that doesn't utilize styling in latest 4.1.2 release.

comment:1 Changed 6 years ago by Wiktor Walc

  1. From which version of CKEditor did you upgrade to 4.1.2? Was it 3.x, 4.0.x, 4.1.x?
  1. Do you still have the old version of CKEditor somewhere, where "Numbered List Properties" was available? Could you attach build-config.js from the old CKEditor package and the new package?
Last edited 6 years ago by Wiktor Walc (previous) (diff)

comment:2 Changed 6 years ago by Jakub Ś

Keywords: setData html issues removed
Resolution: invalid
Status: newclosed
Version: 4.1.2
  1. I have checked this in standard editor version
    var editor = CKEDITOR.replace( 'editor1', {allowedContent : true});	
    CKEDITOR.on( 'instanceReady', function( event ) {
    	editor.setData('<ol start="1" style="list-style-type: upper-alpha;"><li></ol>'); 
    });
    

It works provided that you disable ACF or define rules for it.
I CKEditor 4.1 we have introduced ACF. All plugins included into build have to register to ACF. In standard version there is no plugin that registers alpha style for lists thus you have to adjust ACF to allow it.
For more information about ACF please see: http://ckeditor.com/blog/Upgrading-to-CKEditor-4.1 http://ckeditor.com/blog/CKEditor-4.1-RC-Released
http://docs.ckeditor.com/#!/guide/dev_advanced_content_filter
http://docs.ckeditor.com/#!/api/CKEDITOR.filter-method-addTransformations
http://docs.ckeditor.com/#!/api/CKEDITOR.config-cfg-allowedContent
http://docs.ckeditor.com/#!/api/CKEDITOR.config-cfg-extraAllowedContent

  1. Same as above. To get this table working you would have to use something like below in standard version CKEDITOR.replace( 'editor1', {extraAllowedContent : '*[style,class];*(*);*{*}; style'} );
  1. Standard version doesn't include List Style plugin. Use full version or make your custom build with builder if you need it - http://ckeditor.com/builder

comment:3 Changed 6 years ago by Dennis Plotzke

Confirmed recommended fix for items 1 and 2 by adding the following the config.js:

config.allowedContent = true;

comment:4 Changed 6 years ago by Jakub Ś

This isn't fix but configuration option.

If you don't need to filter data then it is ok but if you would like to filter some tags then you should consider using ACF.

Note: See TracTickets for help on using tickets.
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy