[Webkit-unassigned] [Bug 11361] New: Dynamically added script element is executed twice if its parent is also a dynamically create element
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Oct 19 13:43:26 PDT 2006
http://bugs.webkit.org/show_bug.cgi?id=11361
Summary: Dynamically added script element is executed twice if
its parent is also a dynamically create element
Product: WebKit
Version: 419.x
Platform: Macintosh
OS/Version: Mac OS X 10.4
Status: UNCONFIRMED
Severity: Normal
Priority: P2
Component: JavaScriptCore
AssignedTo: webkit-unassigned at opendarwin.org
ReportedBy: mharder at microsoft.com
It seems that a dynamically added script element is executed twice if its
parent is also a dynamically create element. Consider the following code:
var script1 = document.createElement("script");
script1.type = "text/javascript";
script1.innerHTML = "alert('script1');";
var container = document.createElement("div");
container.appendChild(script1);
document.body.appendChild(container);
When this code is run, the "alert('script1');" code is executed twice. If you
change the last line to:
document.body.appendChild(script1);
Then the "alert('script1');" code is only executed once.
--
Configure bugmail: http://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the webkit-unassigned
mailing list