Modify ↓
Ticket #7537 (closed bug: invalid)
attr('onload') returns null when a string is actually present as a DOMElement attribute
| Reported by: | IgorMinar | Owned by: | |
|---|---|---|---|
| Priority: | undecided | Milestone: | 1.5 |
| Component: | unfiled | Version: | 1.4.4 |
| Keywords: | Cc: | ||
| Blocking: | Blocked by: |
Description
element.attr('onload') should return whatever the value is returned via DOMElement#getAttribute('onload'), currently it returns null in some cases, see example:
Change History
comment:2 Changed 20 months ago by IgorMinar
This was a valid bug, that was fix in 1.6.4 or some previous version: http://jsfiddle.net/IgorMinar/d6cuH/6/
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.
Note: See
TracTickets for help on using
tickets.

Thanks for the report, but this is not a jQuery bug. You are trying to create namespaced elements in an HTML document (impossible), and are passing invalid JavaScript to an onload event handler (also impossible). Selecting onload works fine in wellformed HTML: testcase