I'm making a jigsaw puzzle in HTML. There's a table which has empty spaces and below the table there are pieces which fit exactly into the empty spaces.
So I know how to get the draggable and droppable element on drop and how do get the draggable element on drag. But how do I get the droppable element in which the draggable element currently resides on drag event. Also if a draggable element isn't inside a droppable element it shouldn't break the code.
http://altement.ee/overflow/ click on on a button to start the puzzle too see what I have made. I need to know in which droppable element it is in right now to know if it is in a correct spot already or not.