[jQuery] setting "name" attribute
I'm not sure if this already came up in the mailing list, I couldn't find it.
As you know, setting the "name" attribute on an input field cannot be done in IE like:
$('input').set('name', 'something');
Is it the intent of jQuery to deal with browser inconsistencies like this? Because a workaround would increase the codebase size (maybe slightly, maybe not) but it would also increase its reliability.
Since it has to work dynamically, the workaround not only needs to create it differently, perhaps with something like:
(bear with the pseudocode)
newInput = document.createElement(input.outerHTML.replace(someRegex, myName));
$(newInput).transferEvents(input); // or something
$(input).after(newInput).remove();
thoughts?
-Brito
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/