Bug Tracker

Opened 6 years ago

Closed 6 years ago

#8585 closed bug (invalid)

$(#id #id) selector doesn't work on IE7

Reported by: narmirzaei@… Owned by:
Priority: undecided Milestone: 1.next
Component: unfiled Version: 1.4.4
Keywords: Cc:
Blocked by: Blocking:


I Used $("#propContent #imgExpander").each(...);

to select all the #imgExpander from #propContent but it doesn't work on IE7 (and IE8 on Windows XP)

Instead, I changed the selector to: $("#propContent img[id=imgExpander]").each(...);

and It works fine now.

Change History (1)

comment:1 Changed 6 years ago by ajpiano

  • Resolution set to invalid
  • Status changed from new to closed

"to select all the #imgExpander"

ID's are required to be unique in the DOM. If you have more than element in your DOM with the same ID, jQuery's $("#foo") is not going to work right.

Note: See TracTickets for help on using tickets.