Opened 11 years ago
Closed 11 years ago
#11598 closed bug (wontfix)
$('li').removeAttr('value');//IE Error
Reported by: | anonymous | Owned by: | anonymous |
---|---|---|---|
Priority: | low | Milestone: | None |
Component: | attributes | Version: | 1.7.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
eg.: <li value='1'>abc</li> $('li').removeAttr('value');IE Error
Change History (2)
comment:1 Changed 11 years ago by
Owner: | set to anonymous |
---|---|
Status: | new → pending |
comment:2 Changed 11 years ago by
Component: | unfiled → attributes |
---|---|
Priority: | undecided → low |
Resolution: | → wontfix |
Status: | pending → closed |
Please note that use of the value attribute on <li> elements has been deprecated for quite some time (HTML 4.01) http://www.w3.org/TR/1999/REC-html401-19991224/struct/lists.html#h-10.2.
In my opinion, rather than trying to fix this issue, I recommend the OP use data attributes for storing values instead as these are more flexible. $(el).removeAttr() appears to work fine for other cases where value is still semantically valid.
(If anyone strongly disagrees with this, please feel free to reopen) :)
Note: See
TracTickets for help on using
tickets.
Thanks for taking the time to contribute to the jQuery project! Please provide a complete reduced test case on jsFiddle to help us assess your ticket.
Additionally, be sure to test against the jQuery Edge version to ensure the issue still exists. To get you started, use this boilerplate: http://jsfiddle.net/FrKyN/ Open the link and click to "Fork" (in the top menu) to get started.