Opened 15 years ago
Closed 15 years ago
#4243 closed Bug (worksforme)
Protected tag not rendered right with insertElement
Reported by: | Stefan | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | CKEditor 3.1 |
Component: | General | Version: | 3.0 RC |
Keywords: | Confirmed WorksForMe | Cc: |
Description
I configured a tag for protection:
Excerpt from config.js
CKEDITOR.editorConfig = function( config ) { config.protectedSource.push(/<protected>.*?<\/protected>/g); // ... };
The following
editor.insertHtml('<mct>some text <protected>foobar</protected></mct>');
produces 'some text' in editor.
The following code produces some missbehaviour:
var mct = CKEDITOR.dom.element('mct', editor.document); mct.setHtml('some text <protected>foobar</protected>'); editor.insertElement(mct);
I see 'some text foobar'.
Switch on source view.
Switch off source view.
I see 'some text'.
Change History (5)
comment:1 Changed 15 years ago by
Keywords: | Confirmed added |
---|---|
Milestone: | CKEditor 3.x → CKEditor 3.1 |
comment:2 Changed 15 years ago by
Owner: | set to Garry Yao |
---|---|
Status: | new → assigned |
comment:3 Changed 15 years ago by
Keywords: | WorksForMe added |
---|
The 'insertHtml' function works correctly for me in this sense, Fred could you confirm it again?
Ticket Test added at : http://ckeditor.t/tt/4243/1.html.
comment:4 Changed 15 years ago by
Owner: | Garry Yao deleted |
---|---|
Status: | assigned → new |
comment:5 Changed 15 years ago by
Resolution: | → worksforme |
---|---|
Status: | new → closed |
The element::setHtml behavior cannot be controlled by us, but the insertHtml function should definitely handle this situation properly.