0

How do I get the Draggable Element on stop event? the JQuery UI documentation indicates that the ui parameter only gives helper, position and offset. unlike the resizable's stop event which ui.element is available.

Louie Almeda
  • 5,366
  • 30
  • 38

1 Answers1

0

You can simply use $(this)

This will refer to the element that you are dragging.

i.e.

$("div").draggable({
    stop:function(e, ui) {
       var draggedElement = $(this);
    }
});
haxtbh
  • 3,467
  • 1
  • 21
  • 22