Bug Tracker

Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#10861 closed bug (worksforme)

prepend error in IE9

Reported by: AndyKirk Owned by:
Priority: low Milestone: None
Component: manipulation Version: 1.7.1
Keywords: Cc:
Blocked by: Blocking:

Description

Hi, I couldn't find a ticket describing this problem, so sorry if it's a duplicate.

IE9 (win7) seems to throw an error:

SCRIPT65535: Invalid calling object jquery-1.7.js, line 6002 character 5

When running trying to append newly created elements assigned to a variable:

<ul id="test">

<li>An item</li>

</ul>

$(function() {

item = $('<li>Should be first</li>'); $('#test').prepend(item); });

http://jsfiddle.net/AndyKirk/dGSFe/3/

Change History (3)

comment:1 Changed 11 years ago by anonymous

Oh, sorry, tested in FF8 & Chrome 15 and it works fine. Thanks.

comment:2 Changed 11 years ago by timmywil

Component: unfiledmanipulation
Priority: undecidedlow
Resolution: worksforme
Status: newclosed

http://jsfiddle.net/timmywil/dGSFe/4/

I'm not sure the issue there, but if item is not declared globally, everything works as expected.

comment:3 Changed 11 years ago by dmethvin

There appears to be a global window.item variable in IE9 that is native code.

http://jsfiddle.net/dmethvin/Dg7mf/

Note: See TracTickets for help on using tickets.