It's not working:
draggable.options.revert is not working...
Any other suggestions?
Date: Sun, 26 Feb 2006 19:39:24 -0500
From: [EMAIL PROTECTED]
To: rails-spinoffs@lists.rubyonrails.org
Subject: Re: [Rails-spinoffs] Question abour Draggables & Droppables
>From the wiki:
OnDrop: Called whenever a Draggable is released over the Droppable and the Droppable is accepts it. The callback gets two parameters: the Draggable element, and the Droppable element
Never actually tried this, but:
onDrop: function(draggable,droppable){ draggable.options.revert = false; }
should work, right? Not sure when the revert() function gets invoked though...
-Jerod
On 2/26/06, ::Alex Rengel:: <[EMAIL PROTECTED]> wrote:Hi,
What I need to know is how to change revert:true to revert:false from a draggable after I drop it on a droppable so it doesn't return to its original place.
Something like:
[CODE]
<!-- Draggable image -->
<img alt="Product" id="item" src="icon.png">
<script type="text/_javascript_"> new Draggable(item,{revert:true});</script>
<!-- Droppable Div -->
<div id="droparea" style="height:100px;width:100px;">
<script type="text/_javascript_">
//Droppable Cart
Droppables.add('droparea', {onDrop:function(element, dropon, event){ /* REVERT FALSE */ }});
</script>
[/CODE]
Thank you in advance!
Express yourself instantly with MSN Messenger! MSN Messenger
_______________________________________________
Rails-spinoffs mailing list
Rails-spinoffs@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
Express yourself instantly with MSN Messenger! MSN Messenger
_______________________________________________ Rails-spinoffs mailing list Rails-spinoffs@lists.rubyonrails.org http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs