Bug Tracker

Opened 10 years ago

Closed 10 years ago

#6089 closed bug (invalid)

Next Siblings (“prev ~ siblings”) and :contains() Selectors

Reported by: alexn Owned by:
Priority: Milestone: 1.4.2
Component: selector Version: 1.4.1
Keywords: :contains Cc:
Blocked by: Blocking:

Description

$('#divID1 ~ #divID2 button').length returns 2 elements as expected, but $("#divID1 ~ #divID2 button:contains('Second')").length returns 0 elements, which is not correct - it should return 1 button element with the 'Second' text.

Tested in Google Chrome 4.0, jQuery 1.4.1

Example:

<div>

<div id="divID1">Some text</div>

<div id="divID2">

<button type="button">First</button>

<button type="button">Second</button>

</div>

</div>

Attachments (1)

test.html (771 bytes) - added by alexn 10 years ago.

Download all attachments as: .zip

Change History (2)

Changed 10 years ago by alexn

Attachment: test.html added

comment:1 Changed 10 years ago by john

Resolution: invalid
Status: newclosed

I think you perhaps meant to do [value*=Contains].

Note: See TracTickets for help on using tickets.