Bug Tracker

Opened 15 years ago

Closed 14 years ago

Last modified 11 years ago

#2845 closed bug (fixed)

Sortable that has OBJECT tag generates error in IE

Reported by: tokyotoejam Owned by: paul
Priority: major Milestone: 1.3.2
Component: core Version: 1.3.1
Keywords: sortable Cc:
Blocked by: Blocking:


I have group of Sortables divs. One of the divs has a simple OBJECT that imbeds a youtube video. In IE when I try to drag this div around, it generates an error at line 310 saying "Object doesn't support this property or method". When I remove the OBJECT Tag, I do not get an error so I am thinking that the sortables dont like the OBJECT tag in IE. (Other browsers work fine)

Change History (4)

comment:1 Changed 15 years ago by paul

Status: newassigned

comment:2 Changed 14 years ago by emartin24

Any updates on this? There was just another ticket opened for the same issue http://dev.jquery.com/ticket/3289.

The following is a simple example, which throws an error in IE6 & 7:

<script type='text/javascript'>
$(document).ready(function () {
	var clone = $('#videobox').clone(true);

<div id="videobox" style='display:none;'>
	<object width="425" height="355">
		<param name="movie" value="http://www.youtube.com/v/JikaHBDoV3k&hl=en"></param>
		<param name="wmode" value="transparent"></param>
		<embed src="http://www.youtube.com/v/JikaHBDoV3k&hl=en" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"></embed>

comment:3 Changed 14 years ago by Baryn

I have a bit of a workaround for this bug, until someone can confront it head-on. This will effectively clone ANY element, including OBJECTs.

  var theElement = $(YOUR-SELECTOR-HERE).wrap('<div></div>').parent().html();

"theElement", in this case, is a carbon copy of your OBJECT element's code, do with it what you will (except clone ;). The second line "unwraps" the original OBJECT.

A caveat: This will not clone event listeners (unless they are as attributes), but I doubt you have events attached to a media object, so no biggie. In any case, you can manually re-attach them if necessary.

Brian B, Head of Frontend Development, 360i LLC

comment:4 Changed 14 years ago by john

Component: uicore
Resolution: fixed
Status: assignedclosed

Fixed in SVN rev [6186].

Note: See TracTickets for help on using tickets.