I’m creating a drag and drop application and what I want to do is while the user is dragging an element get if the cursor is over certain other element.
Heres the flow:
User starts dragging an element around the page
When the mouse gets over certain parts I want to make an ajax call.
Because I know the elements and their bounds via jquery I just want the best way to make the check.
Start here: http://docs.jquery.com/Tutorials:Mouse_Position
Get the mouse coordinates and compare it to the
.offset()values of the item you’re comparing it to.http://api.jquery.com/offset/