Bug Tracker

Opened 13 years ago

Closed 12 years ago

#5282 closed bug (worksforme)

Elements have different order after find("*") and filter() in IE7

Reported by: leif Owned by: leif
Priority: low Milestone: 1.3.2
Component: selector Version: 1.3.2
Keywords: dom order Cc:
Blocked by: Blocking:


$cloned = $(this).clone(true); $elements = $(this).find("*").andSelf().filter("textarea, select"); $clonedElements = $cloned.find("*").andSelf().filter("textarea, select");

The above snippet gets all elements in the set of $(this). It filters for textareas and selects in the original set and a cloned set. The elements in the sets have different orders, more precisely, they are sorted by type, first textareas then selects. The filtered elements from the cloned set are in a different order. Sometimes this only works once after page reload.

If you filter elements like this: $clonedElements = $cloned.find("textarea, select").andSelf(); they do not get a new order.

Change History (3)

comment:1 Changed 13 years ago by dmethvin

Component: unfilledselector
Keywords: dom order added
Owner: set to john

comment:2 Changed 12 years ago by dmethvin

Owner: changed from john to leif
Status: newpending

Can you provide the markup as well?

comment:3 Changed 12 years ago by jitter

Priority: majorlow
Resolution: worksforme
Status: pendingclosed

test case works for me.

I believe this bug has been fixed as of jQuery 1.3.2. If you feel this ticket was closed incorrectly, feel free to report back with a reproducible test case and reopen the issue.

Note: See TracTickets for help on using tickets.