Opened 13 years ago
Last modified 13 years ago
#8977 confirmed Bug
CKEditor locks the browser (javascript loop) with certain contents
Reported by: | Alessandro Polverini | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | 3.0 |
Keywords: | Cc: |
Description
When CK is instantiated with some kind of contents there is some kind of loop (I think it's on the parser) that locks the browser.
Tested with chrome and FF.
I attach a simple html with a test case that shows the behavior
Attachments (1)
Change History (7)
Changed 13 years ago by
Attachment: | bug-3.6.3.html added |
---|
comment:1 Changed 13 years ago by
comment:2 Changed 13 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
You have used invalid HTML that is why you have got weird result.
<title></title> <meta name="GENERATOR" ></meta>
Removing just one of the above works.
title: - http://www.w3schools.com/tags/tag_title.asp - there can be only one title tag on page you have used two
meta - http://www.w3schools.com/tags/tag_meta.asp - your page uses HTML4 where meta tag is allowed in head section only (There is microdata in HTML5 http://www.w3.org/TR/html5/microdata.html which allows for meta tags across the body but this is not the case here - wrong HTML version and wrong syntax for microdata).
comment:3 Changed 13 years ago by
The text is entered by the user (via other means) and thus it can by of any kind.
I dont't find right that the parser goes in loop in this case. Also, older FCK handled it correctly without any problem.
Can this bug be reopened please?
Any kind of input that make loop the parser should be regarded as a bad bug, IMHO.
comment:4 Changed 13 years ago by
I also agree that hanging the editor because the user has pasted some bad content isn't very user friendly and should never happen.
comment:5 Changed 13 years ago by
Resolution: | invalid |
---|---|
Status: | closed → reopened |
comment:6 Changed 13 years ago by
Status: | reopened → confirmed |
---|---|
Version: | → 3.0 |
This decision was actually consulted: P
@alfonsoml, @Alex, agreed that CKEditor should not go into infinite loop no matter what you paste
@Alex - meta tag suggests that such "template" was made by generator - I don't know who wrote it but if you have access to its source code then maybe you should think of correcting it.
Problem occurs in:
URI: ckeditor\_source\core\htmlparser\fragment.js
Code: if ( currentNode.parent ) addElement( currentNode, currentNode.parent, 1 );
Loop happens when meta tag is processed.
The attach is a self-contained html page exhibiting the problem: the JS code runs in loop blocking the page in the browser.