Modify ↓
Ticket #5057 (closed bug: invalid)
html('') remove all the children's events
| Reported by: | agate | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | 1.4 |
| Component: | core | Version: | 1.3.2 |
| Keywords: | html event | Cc: | |
| Blocking: | Blocked by: |
Description
$.html(val) will remove all children nodes. and all the events which bind on these children nodes.
but if i use DOM.innerHTML = val, the children's events will be kept. so that i can use append function to append the children back to the dom tree. and the children's evnets still can be triggered.
Attachments
Change History
Changed 4 years ago by agate
-
attachment
index.html
added
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.

jquery html() remove all the children's events