Side navigation
#9458 closed bug (invalid)
Opened May 29, 2011 04:20PM UTC
Closed June 01, 2011 06:09PM UTC
:not() selector problem?
Reported by: | johnfirth2@gmail.com | Owned by: | |
---|---|---|---|
Priority: | undecided | Milestone: | 1.next |
Component: | unfiled | Version: | 1.6.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
With regard to this http://stackoverflow.com/questions/1730609/using-jquery-not-selector-to-exclude-elements-with-particular-children/6157579#6157579
the first suggestion in Russ Cam's post, i.e:
$("div.divToAppendTo:not(div > span.myAppendedMarkup)")
doesn't seem to work. It selects all the divs rather than just those without the span child. I don't, however, understand why it doesn't work, so I'm raising it as a possible bug.
Hope I'm not wasting your time.
Attachments (0)
Change History (3)
Changed May 29, 2011 04:55PM UTC by comment:1
Changed May 31, 2011 03:55AM UTC by comment:2
From what I can see, the reason the provided suggestion doesn't seem to work is that the selector in the :not selects all of the span elements with the given class rather than the parent DIV
Changed June 01, 2011 06:09PM UTC by comment:3
resolution: | → invalid |
---|---|
status: | new → closed |
In the first you're *selecting* the span, which does not match any div.
http://jsfiddle.net/Joffer/N9Kqe/