# Drag/Drop with Image Maps

**URL:** <https://www.ruby-forum.com/t/drag-drop-with-image-maps/143133>\
**Category:** Rails\
**Created:** [July 15, 2008, 3:41pm UTC](https://www.ruby-forum.com/t/drag-drop-with-image-maps/143133 "2008-07-15T15:41:16Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![adam](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/4af34b/32.png) [@adam](https://www.ruby-forum.com/u/adam)\
**Post date:** [July 15, 2008, 3:41pm UTC](https://www.ruby-forum.com/t/drag-drop-with-image-maps/143133/1 "2008-07-15T15:41:16Z")

</div>

Hi all,

Is it possible to use HTML area objects from an image map as  
droppables for a drag/drop interface? I want to get a different  
response depending on which part of an image I drop a draggable div  
object on. The context is creating an incident report form where  
injuries can be dragged onto a body sketch. I’ve tried this using the  
code below. However, the droppable is always identified as  
“front\_head”, the first area object, no matter which part of the image  
is dropped on. Has anyone managed to get this working successfully, or  
found a way to achieve a similar effect?

Many thanks,  
Adam

\<%= image\_tag “body\_sketch\_front.gif”, :usemap =\> “#front” -%\>

punch

kick
