Added a fix for <script>s getting executed twice when .load()ed.
authorJohn Resig <jeresig@gmail.com>
Wed, 10 Jan 2007 21:31:18 +0000 (21:31 +0000)
committerJohn Resig <jeresig@gmail.com>
Wed, 10 Jan 2007 21:31:18 +0000 (21:31 +0000)
src/ajax/ajax.js

index f87f562..0c629b3 100644 (file)
@@ -77,7 +77,7 @@ jQuery.fn.extend({
                        complete: function(res, status){
                                if ( status == "success" || !ifModified && status == "notmodified" )
                                        // Inject the HTML into all the matched elements
-                                       self.html(res.responseText)
+                                       self.attr("innerHTML", res.responseText)
                                          // Execute all the scripts inside of the newly-injected HTML
                                          .evalScripts()
                                          // Execute callback