1
這裏是我想要做的 HTML如何在jQuery UI中使用Draggable和Droppable將拖動的li添加到droppable ui中?
<ul class="droppable"> </ul>
<ul class="droppable">
<li class="draggable"> Item 1</>
<li class="draggable"> Item 2</>
</ul>
jQuery的
$(function() {
$(".draggable").draggable();
$(".droppable").droppable({
drop: function (event, ui) {
alert("Dropped!");
}
});
});
我想拖李到另一個UL和李有權追加到下降UL。
http://stackoverflow.com/questions/1254665/jquery-draggable-droppable-how-to-snap-dropped-element-to-dropped-on-element Thnks到@Barry Pitman – Atul