Response title
This is preview!
$("#dragable").animate({
function() {$("#dragable").appendTo("#dropable");}
}, 1000 );
animate
--------
The key aspect of this function is the object of style properties that will be animated, and to what end
$("#dropSlot1").droppable({
drop: function(event, ui) {
$("#dragWea").appendTo("#dropSlot1")
}
});
div{
background: #F00;
width: 100px;
height: 100px;
position: absolute;
left: 200px;
top: 200px;
}
<a href="#">Click me</a>
<div></div>
$("a").click(function(){
$("div").animate({ left: "250px", top: "100px"}, 1000)
.animate({ left: "400px", top: "200px"}, 1000)
.animate({ left: "350px", top: "500px"}, 1000)
.animate({ left: "250px", top: "250px"}, 1000)
});
© 2013 jQuery Foundation
Sponsored by and others.