From: Paul Bakaus Date: Mon, 24 Nov 2008 13:48:50 +0000 (+0000) Subject: sortable: Another regex for the innerHTML copying in the placeholder, removes the... X-Git-Tag: 1.6rc3~379 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=19a7d6bc5bceb82892b063f678740ae09b630973;p=jquery-ui.git sortable: Another regex for the innerHTML copying in the placeholder, removes the expando attribute in IE (fixes #3541) --- diff --git a/ui/ui.sortable.js b/ui/ui.sortable.js index 465dd5ea5..d2b337837 100644 --- a/ui/ui.sortable.js +++ b/ui/ui.sortable.js @@ -646,7 +646,9 @@ $.widget("ui.sortable", $.extend({}, $.ui.mouse, { if(!className) { el.style.visibility = "hidden"; document.body.appendChild(el); - el.innerHTML = self.currentItem[0].innerHTML.replace(/name\=\"[^\"\']+\"/g, ''); //Name attributes are removed, otherwice causes elements to be unchecked + // Name attributes are removed, otherwice causes elements to be unchecked + // Expando attributes also have to be removed because of stupid IE (no condition, doesn't hurt in other browsers) + el.innerHTML = self.currentItem[0].innerHTML.replace(/name\=\"[^\"\']+\"/g, '').replace(/jQuery[0-9]+\=\"[^\"\']+\"/g, ''); document.body.removeChild(el); };