Forum: Ruby on Rails How to drag & drop within a DIV?

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Charlie (Guest)
on 2006-04-25 18:55
Suppose some elements created using scriptaculous, and now want to add
drag&drop characteristic to them,but the draggable elements can be
dragged with the scope of whole browser,how to limit the draggable area
within some DIV,for example the div that the elements lie in.

seth b. (Guest)
on 2006-05-24 10:53
(Received via mailing list)
I've found messing with the overflow property of a div limit the
dragging -
which I don't like.

If you contain the items within a div that's got 'overflow:auto' set on
you can't drag outside the div.

I'm guessing overflow:hidden will work the same way.
This topic is locked and can not be replied to.