Bug Tracker

Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#11521 closed bug (wontfix)

JS error on IE <= 8 when jQuery objects containing HTML5 are inserted to DOM

Reported by: Haprog Owned by: Rick Waldron
Priority: undecided Milestone: None
Component: manipulation Version: 1.7.2
Keywords: Cc:
Blocked by: Blocking:

Description

Here's a simple fiddle that demonstrates the problem: http://jsfiddle.net/Haprog/5MnDG/

You get a JavaScript error on IE8 and older when using the latest html5shiv and jQuery 1.7.2. The problem also appears on jQuery 1.7.1 and edge.

Tested on Windows 7 (32bit and 64bit) using IETester, and Windows XP with IE8 on VirtualBox.

The problem doesn't occur on IE9, Firefox 11 or Chrome 18.

The error you get on IE8 and older is "'nodeType' is null or not an object" in jQuery (edge) and 1.7.2 on line 6101, char 2, (or jQuery 1.7.1 on line 6001) in function cloneCopyEvent()

More info in the JS comments of the fiddle. Seems like this may be related to #6485

I found this while working on an AJAX application that completely stopped working on IE8 and older because of this issue, before I figured out what was the cause and found the workaround that's mentioned in the JS comments of the fiddle.

Change History (5)

comment:1 Changed 7 years ago by Rick Waldron

Component: unfiledmanipulation
Owner: set to Rick Waldron
Status: newassigned

comment:2 Changed 7 years ago by Rick Waldron

When the newest html5shiv was being developed, I had tested the against the latest jQuery without any issues - it looked like the html5shiv guys had it under control. jQuery is tested using the original, minimal shiv code.

comment:3 Changed 7 years ago by Rick Waldron

Resolution: wontfix
Status: assignedclosed

I just spoke with John-David Dalton who informed me that this was a known issue with html5shiv that has been fixed on their end and will be fixed in the next release. In the mean time, here is the edge code to use:

http://raw.github.com/aFarkas/html5shiv/master/src/html5shiv.js

comment:4 Changed 7 years ago by Haprog

Thank you for the information! Everything seems to be working well when using that latest edge version of html5shiv. :)

comment:5 Changed 7 years ago by Haprog

Hmm.. now the previous URL doesn't seem to work as is, but it works with https. https://raw.github.com/aFarkas/html5shiv/master/src/html5shiv.js

Note: See TracTickets for help on using tickets.