Bug Tracker

Opened 9 years ago

Closed 9 years ago

#6092 closed bug (wontfix)

IE7/8 Bug with id based searching

Reported by: Cameron Owned by:
Priority: Milestone: 1.4.1
Component: core Version: 1.4.1
Keywords: Cc:
Blocked by: Blocking:

Description

<div id="abc">

<div id="ghi">

test 1

</div> <div id="def">

test 2

</div>

</div>

<div id="jkl">

<div id="def">

test 3

</div>

</div>

<script language="JavaScript">

$('#abc #def').css("border","3px solid red"); $('#jkl #def').css("color", "green");

</script>

The 2nd line of the script will not function and returns a null. The last version that works properly is 1.2.6 I have tried all versions from 1.2.6 up through 1.4.1 and all are affected.

Change History (1)

comment:1 Changed 9 years ago by john

Resolution: wontfix
Status: newclosed

You really shouldn't be using multiple identical IDs in a document - I recommend using classnames instead as that will avoid any potential collisions. IDs are meant to be unique across the entire document.

Note: See TracTickets for help on using tickets.