Skip to main content

Bug Tracker

Side navigation

#4755 closed bug (worksforme)

Opened June 12, 2009 03:27PM UTC

Closed October 29, 2010 06:39PM UTC

Unable to match HTML nodes with $(n1).find("*").is(n2)

Reported by: sigr0005 Owned by: sigr0005
Priority: major Milestone: 1.4
Component: selector Version: 1.3.2
Keywords: traversing, is, events Cc:
Blocked by: Blocking:


var e2 = [e1 is a child of e2 but could also be e2];

$(e1).mouseleave(function() {


isChild = $(e2).find("*").andSelf().is(e1);

if(isChild) alert("This alert is NEVER reached :(");



replace isChild so that,

isChild = e2.find("*").andSelf().not(e2.find("*").andSelf().not(e1)).is(e1);

It appears that "not()" is the only traversing function working in this case.

Attachments (0)
Change History (4)

Changed June 16, 2009 01:31AM UTC by dmethvin comment:1

Can you attach a complete test case? Thanks.

Changed October 29, 2010 06:13AM UTC by addyosmani comment:2

owner: johnsigr0005
status: newpending

Please submit your ticket with a test case reproducing this issue on jsFiddle.

Changed October 29, 2010 04:17PM UTC by sigr0005 comment:3

status: pendingnew

Appears to be working just fine now ;-)


Changed October 29, 2010 06:39PM UTC by snover comment:4

resolution: → worksforme
status: newclosed