#4054 closed defect (fixed)
JS exception in Editor code on dojo.query() call: body not found
Reported by: | bill | Owned by: | liucougar |
---|---|---|---|
Priority: | high | Milestone: | 0.9 |
Component: | Query | Version: | 0.9 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description (last modified by )
Problem when loading Editor with a stylesheet specified over http://, (not file://). Happens in themeTester.html. Breaks on line 647:
dojo.query("body", this.document.documentElement)[0].innerHTML = html;
Problem is that this.document.documentElement.innerHTML at this point is
<head> <style>body,html { background:transparent; padding: 0; margin: 0;}body{ top:0px; left:0px; right:0px;position: fixed; font:400 13px "Myriad Pro",Myriad,Arial,Helvetica,clean,sans-serif; min-height:1em; line-height:1.0}p{ margin: 1em 0 !important; }body > *:first-child{ padding-top:0 !important;margin-top:0px !important;}body > *:last-child { padding-bottom:0 !important; margin-bottom:0px !important;}li > ul:-moz-first-node, li > ol:-moz-first-node{ padding-top: 1.2em; } li{ min-height:1.2em; }</style> <link rel="stylesheet" type="text/css" href="http://mac.local/0.9/dojo/resources/dojo.css"> </head>
The <body></body> tags are getting cutoff even though we set them. There's a line of code:
setTimeout(ifrFunc, 250);
If I change 250 to 5000 it works.
But I'm wondering why we have to set innerHTML at all. Why not just pass the body text to _getIframeDocTxt()? Is it so we can reset the editor text from a setValue() call?
Change History (6)
comment:1 Changed 15 years ago by
comment:2 Changed 15 years ago by
Description: | modified (diff) |
---|---|
Summary: | JS exception in Editor code on themeTester.html load (FF) → JS exception in Editor code on dojo.query() call: body not found |
The problem is only happening for me on FF/Mac but it's a race condition (on top of a firefox bug). I updated the bug description above to be more accurate.
comment:3 Changed 15 years ago by
Description: | modified (diff) |
---|
comment:4 Changed 15 years ago by
comment:6 Changed 13 years ago by
Component: | Editor → Query |
---|
loaded fine in my IE 6
what you did to see the breaks?