Skip to main content

Bug Tracker

Side navigation

#4468 closed bug (duplicate)

Opened April 01, 2009 05:09PM UTC

Closed July 11, 2011 06:10PM UTC

Last modified July 11, 2011 06:11PM UTC

:not() Selector not working properly with :first in IE browsers

Reported by: swalke16 Owned by: john
Priority: low Milestone: 1.next
Component: selector Version: 1.4.4
Keywords: not first Cc:
Blocked by: Blocking:
Description

If I have a selector such as the following:

$('.value-container:not(:first)').remove();

This will remove ALL elements that have the value-container class when using an IE browser. When using Firefox this works correctly and removes all but the first element that has the value-container class.

Attachments (1)
  • NotBug.htm (0.7 KB) - added by swalke16 April 01, 2009 05:09PM UTC.

    Simple HTML page that reproduces the described issue.

Change History (6)

Changed September 25, 2009 03:03AM UTC by mellamokb comment:1

Just found the same issue. $('.value-container').not(':first') seems to be a suitable workaround for both IE and FF.

Changed November 19, 2010 01:56AM UTC by dmethvin comment:2

milestone: 1.3.2
priority: majorlow
status: newopen
version: 1.3.21.4.4

Changed January 23, 2011 08:29PM UTC by anonymous comment:3

Replying to [comment:1 mellamokb]:

Just found the same issue. $('.value-container').not(':first') seems to be a suitable workaround for both IE and FF.

Thanks - so much - found this doing a google search and it was the perfect answer.

Changed March 31, 2011 04:41AM UTC by danheberden comment:4

milestone: → 1.next

Still present on IE6-8. Works as expected on IE9 and other browsers.

A more visual test-case:

http://jsfiddle.net/danheberden/ZBX76/

Changed July 11, 2011 06:10PM UTC by john comment:5

resolution: → duplicate
status: openclosed

Changed July 11, 2011 06:11PM UTC by john comment:6

Duplicate of #4028.