My guess: because e.target on mouseup may refer to the element you are dragging (or its drag-ghost). If you drag an element and it (or a translucent ghost element) follows your cursor, as when dragging a file onto the desktop, your mouse will always be above the element that you drag when you click the mouse.
Alternatively, if there is no cursor and no ghosting, e.target may refer to the element inside the "dropzone element", and not to the area itself.
For example:
<div id="dropzone_element"> <div id="previously_dropped_element" /> <div> <div id="draggable_element" />
So, if you drag and drop the drop element over the dropzone element and release the mouse, you will actually free the mouse over the previously dropped element inside the dropzone; not the drop itself.
In both cases, checking the mouse position is the only way to get the correct dropzone element.
That would be my guess, but I do not have IE to test the actual behavior.
Edit: in the 1st case, checking the position is the only way. In the second case, you can also check the target ancestors to find the dropzone element, as indicated by the afé in the comments. If, that is, a previously dropped element was actually inserted into the dropzone hierarchy, and not just positioned as if it were - although it would be very strange:
Flambino
source share