diff --git a/src/core/parseHTML.js b/src/core/parseHTML.js index c501cdfc9..e0348971d 100644 --- a/src/core/parseHTML.js +++ b/src/core/parseHTML.js @@ -17,9 +17,7 @@ jQuery.parseHTML = function( data, context, keepScripts ) { keepScripts = context; context = false; } - // document.implementation stops scripts or inline event handlers from - // being executed immediately - context = context || document.implementation.createHTMLDocument( "" ); + context = context || document; var parsed = rsingleTag.exec( data ), scripts = !keepScripts && []; diff --git a/test/unit/core.js b/test/unit/core.js index c4c5ffa1a..17006a8ab 100644 --- a/test/unit/core.js +++ b/test/unit/core.js @@ -1370,20 +1370,6 @@ test("jQuery.parseHTML", function() { ok( jQuery.parseHTML("<#if>
This is a test.