Opened 10 years ago
Closed 10 years ago
#13875 closed bug (notabug)
An question about jQuery event
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | undecided | Milestone: | None |
Component: | unfiled | Version: | 2.0.0 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
Hi,hear is the step:
- First,use jQuery bind an event for an element,any element, any event.
- Then use a variable save the element in memory.
- Then remove the element form the DOM tree.
- Finally, add the element to the DOM tree.
And here,the event that I bind in my first step is gone. I don't know it's a bug or it's inevitable in jQuery. Hear is my test code:
var tt = $( 'button' ).click( function() {
alert( '13242' );
} );
tt.remove();
$( 'body' ).append( tt );
Thank you very much!
Change History (2)
comment:1 Changed 10 years ago by
comment:2 Changed 10 years ago by
Resolution: | → notabug |
---|---|
Status: | new → closed |
Note: See
TracTickets for help on using
tickets.
This is the bug tracker. Please ask for help on the forum or StackOverflow.