Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Draggable <td> content using jQuery

I would like to use jQuery and its drag-and-drop function, such as: http://jqueryui.com/demos/draggable/

In my case, I would like to enable drag-and-droping on <td> content of an HTML table. For instance with a table of 20x20, in order to move a <img /> tag from a cell to an other cell.

Is that hard to do? I don't see any example after searches. If you're got one or if you can show me how to process, I will be cool!

like image 943
Denis Avatar asked Jan 19 '10 23:01

Denis


1 Answers

Try using jQuery.ui.sortable. That should allow for drag and drop within the table.

like image 77
dgo Avatar answered Oct 09 '22 03:10

dgo