Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Update table content while dragging the element using jquery

my question is can we update the table content while dragging/resizing the div.The content is the position and size of the div that is dragged or re-sized please help mee


1 Answers

Assuming you are using jQuery Draggable, you could use the drag part of it:

$("#draggable").draggable({
    drag: function() {
        var offset = $(this).offset();
         $(this).html(offset.left + ', ' + offset.top);
    }
});

Example: http://jsfiddle.net/QH6QP/

like image 178
Blair McMillan Avatar answered Aug 10 '26 09:08

Blair McMillan



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!