Skip to main content

Bug Tracker

Side navigation

#9921 closed bug (invalid)

Opened July 27, 2011 05:39PM UTC

Closed August 11, 2011 07:55AM UTC

Last modified September 26, 2011 11:31AM UTC

Compound selectors dont work well in IE7

Reported by: stuart.innes@fanduel.com Owned by: stuart.innes@fanduel.com
Priority: low Milestone: None
Component: event Version: 1.4.3
Keywords: Cc:
Blocked by: Blocking:
Description

tried something like in IE7

$(".item1 a, .item2 a").live('click',function(){

//do stuff

})

The script will timeout(prompt to force stop) with medium data-sets (about 150-200 matching items)or takes an inordinate length of time to complete.

Attachments (0)
Change History (4)

Changed July 27, 2011 06:08PM UTC by timmywil comment:1

component: unfiledevent
owner: → stuart.innes@fanduel.com
priority: undecidedlow
status: newpending

Thanks for taking the time to contribute to the jQuery project! Please provide a reduced test case on http://jsfiddle.net that reproduces the issue experienced to help us assess your ticket.

Additionally, test against the jQuery (edge) version to ensure the issue still exists.

Changed July 27, 2011 06:25PM UTC by dmethvin comment:2

It wouldn't surprise me that this peformed poorly in IE6/7, since the only way to satisfy that query is to make a pass through the entire document to find the correct classes and descendants. And it has to be done each time a click occurs. Other browsers support querySelectorAll so they can do this faster.

Try a better-qualified selector, using ids or just a single class selector qualified by a tag name, such as div.itemX.

Changed August 11, 2011 07:55AM UTC by trac-o-bot comment:3

resolution: → invalid
status: pendingclosed

Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!

Changed September 26, 2011 11:31AM UTC by alex@opentech.co.il comment:4

Replying to [ticket:9921 stuart.innes@…]:

tried something like in IE7 $(".item1 a, .item2 a").live('click',function(){ //do stuff }) The script will timeout(prompt to force stop) with medium data-sets (about 150-200 matching items)or takes an inordinate length of time to complete.

the bug is that selecting $('#a #b #c'); is not working in ie7, to solve it I used $('#a #b').find('#c');

this bug should be reopened