Skip to main content

Bug Tracker

Side navigation

#13875 closed bug (notabug)

Opened May 10, 2013 03:10AM UTC

Closed May 10, 2013 03:16AM UTC

An question about jQuery event

Reported by: PerterPon@gmail.com Owned by:
Priority: undecided Milestone: None
Component: unfiled Version: 2.0.0
Keywords: Cc:
Blocked by: Blocking:
Description

Hi,hear is the step:

1. First,use jQuery bind an event for an element,any element, any event.

2. Then use a variable save the element in memory.

3. Then remove the element form the DOM tree.

4. 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!

Attachments (0)
Change History (2)

Changed May 10, 2013 03:15AM UTC by dmethvin comment:1

This is the bug tracker. Please ask for help on the forum or StackOverflow.

Changed May 10, 2013 03:16AM UTC by dmethvin comment:2

resolution: → notabug
status: newclosed