Sam Foster
2005-Sep-08 23:44 UTC
[Rails-spinoffs] Draggables - without moving the original element
I''m needing to implement some drag and drop in a way that leaves the clicked element where it is, and carries a new element over to my Droppable. Its analogous to a shopping cart: I want to drag a representation of an item into my cart, but leave the original item intact in the main product list. Does anyone have any tips on how to approach this? Its seems to use scriptaculous'' dragdrop.js library (which I''m already heavily invested in) I''m going to have to perform some sleight of hand somehow to switch in a different element when the drag starts. This is complicated by the presence of other event handlers on the same element - I cant simply overlay a element that gets dragged as that same element has other behaviour - like a rollover - so I need it to receive the mouseover etc. events. thanks for any pointers. Sam -i-am
Martin Bialasinski
2005-Sep-09 07:01 UTC
[Rails-spinoffs] Draggables - without moving the original element
On 09/09/05, Sam Foster <sam@sam-i-am.com> wrote:> I''m needing to implement some drag and drop in a way that leaves the > clicked element where it is, and carries a new element over to my > Droppable.Adding ghosting: true to the Draggable options should do the trick. See http://wiki.script.aculo.us/scriptaculous/show/GhostlySortableDemo Bye, Martin
Seemingly Similar Threads
- Draggables and Droppable performance (tips)
- Dropables problem on scroll bars
- Question abour Draggables & Droppables
- making an element draggable after it's been dropped in a drop zone
- sortable - after complete dropping element want to send ajax reqeust with id of elements: draggable and droppable