Bug Tracker

Opened 11 years ago

Closed 11 years ago

#12087 closed bug (fixed)

find selector doesn't work any more with an expando containing a coma

Reported by: anonymous Owned by: gibson042
Priority: low Milestone: None
Component: selector Version: 1.8b2
Keywords: Cc:
Blocked by: Blocking:

Description

Hello,

This is the kind of use case I have on my application:

http://jsfiddle.net/zbDvU/1/

It seems that div.find('span[data-expando="AA,BB"]') returns nothing in the 1.8 (it works with the 1.7 version).

As you can see in the test, it also works in the 1.8, without the coma.

Additionally, please note that $('span[data-expando="AA,BB"]') returns results.

Thanks for your work !

Change History (6)

comment:1 Changed 11 years ago by addyosmani

Component: unfiledselector
Priority: undecidedlow
Resolution: worksforme
Status: newclosed

From our documentation:

If you wish to use any of the meta-characters ( such as !"#$%&'()*+,./:;<=>?@[\]`{|}~ ) as a literal part of a name, you must escape the character with two backslashes:

Applying this to your selector results in a test case that works fine: http://jsfiddle.net/WpGGh/

comment:2 Changed 11 years ago by anonymous

ok, I missed that point in the documentation.

I'll change my code accordingly.

Thanks a lot.

comment:3 Changed 11 years ago by gibson042

Resolution: worksforme
Status: closedreopened

comment:4 Changed 11 years ago by gibson042

Owner: set to gibson042
Status: reopenedassigned

comment:6 Changed 11 years ago by Dave Methvin

Resolution: fixed
Status: assignedclosed

Update Sizzle to fix #12082, #12087.

Changeset: f70a696598f14917e49dc108271788e2ec2f6587

Note: See TracTickets for help on using tickets.