#8950 closed bug (fixed)
(Chrome, Firefox) Second argument (event empty) in jQuery throws error while creating <input>
Reported by: | Owned by: | Rick Waldron | |
---|---|---|---|
Priority: | blocker | Milestone: | 1.6.2 |
Component: | manipulation | Version: | 1.5.2 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Link to test: http://theshock.github.com/trash/jquery-input-bug/index.html
// Error: Uncaught TypeError: Object #<Object> has no method 'createDocumentFragment' // Here: if ( !fragment ) { fragment = doc.createDocumentFragment(); // <==== jQuery.clean( args, doc, fragment, scripts ); }
Test code:
$(function() { // success: $('<div />', {}); $('<input>', { 'class': 'test' }); $('<input type="hidden" />').attr({ 'class': '123' }); // fail: $('<input type="hidden" />', { 'class': 'test' }); $('<input type="hidden" />', {});
Change History (7)
comment:1 Changed 12 years ago by
comment:2 Changed 12 years ago by
Component: | unfiled → manipulation |
---|---|
Owner: | set to Rick Waldron |
Priority: | undecided → blocker |
Status: | new → assigned |
comment:4 Changed 12 years ago by
Milestone: | 1.next → 1.6.2 |
---|
comment:5 Changed 12 years ago by
The correct pull request is here: https://github.com/jquery/jquery/pull/365
comment:6 Changed 12 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Landing pull request 365. jQuery.buildFragment, ensure doc is a document; Fixes #8950.
More Details:
Note: See
TracTickets for help on using
tickets.
Test case at jsFiddle: http://jsfiddle.net/YYqgM/