Problems with Draggable clones with jQuery UI and IE
Hello i have a function whats makes a dynamic clone of any widget in the document in all the browsers works perfectly excepts in IE, i've tried everything and nothing works any ideas of the solution I'm desspered.
- function makeDrag(elmnt){
- $(elmnt).draggable({
- cancel: null,
- helper:'clone',
- scroll: true,
- scrollSensitivity: 100,
- stop: function (event)
- {
- if (this.getAttribute('main') == 'true'){
- var clnumb = parseInt(this.getAttribute('clone'));
- var newIndex = (clnumb+1);
- if (getBrowser() == 0){
- /*
- * The special IE
- */
- var idClean = $(this).attr('id').substring($(this).attr('clone').length);
- clone = add2Doc(this, document);
- }else{
- /*
- * All the normals and
- * very usefuls browsers.
- */
- clone = add2Doc(this, document);
- }
- clone.setAttribute('clone', newIndex);
- clone.setAttribute('id', ((newIndex)+clone.getAttribute('id').substring(1)));
- clone.removeAttribute('style');
- $(this).removeAttr('new');
- $(this).removeAttr('main');
- }
- $(this).css({position:'absolute', top:event.pageY,left:event.pageX});
- if(getBrowser() == 0){
- /*
- * IE.
- */
- $(this.parentNode).append(clone);
- $(clone).addClass("draggable").addClass("draggedClone");
- $(this).appendTo('body');
-
- }else{
- /*
- * Everybody.
- */
- $(parent).append(clone);
- $(this).appendTo('body');
- makeDrag(clone);
- }
-
-
- }
- });
- }