Hello,

If each row of a big table was clickable, following best practices, we
should not attach a click handler on each row, we should attach a
click handler on the container, and in the click handler, figure out
which row was clicked.  We can do this by examining event.target.  The
reason for doing this is to save memory.

I've try to do the same thing with drag and drop.  Rather than making
each row droppable.  I want to make the container (table) droppable:

$('#tableID').droppable(
    {
        'accept': '.draggable',
        'drop': function(event,ui) {
            // In this function, $(this) is the jQuery object for the
table
        }
    });

How can I figure out which row was the intended drop target?  I've
poke around the ui object and the event object, but I cannot find any
DOM object for the row that I've dropped the draggable object on.  Has
anyone try something similar?  Am I missing something?

Reply via email to