Should jQuery normalize this IE6 bug involving <input/> names?
Should jQuery normalize this IE6 bug involving <input/> names?
The alerts in following code do not show the same result in IE6 due to
a bug[1] (also discussed on stackoverflow.com[2]). $('<input type="hidden" />').attr('name', 'foo').appendTo (document.body); alert(document.getElementsByName('foo').length); // Alert shows "0" in IE6 and "1" in other browsers $('<input type="hidden" name="bar" />').appendTo(document.body); alert(document.getElementsByName('bar').length); // Alert shows "1" in all browsers. Working demo: http://jsbin.com/urajo Should jQuery normalize or at least warn the user about this discrepancy (like it does when attempting to change the 'type' attribute on <input/> elements)? [1]: http://webbugtrack.blogspot.com/2007/10/bug-235-createelement-is-broken-in-ie.html [2]: http://stackoverflow.com/questions/1650797/setting-name-of-dom-created-element-fails-in-ie-workaround --