I want to do a simple drag-drop using jQuery. I have not done开发者_运维技巧 anything so far, but previous attempts were unsuccessful.
Have you tried jQuery UI Draggable? Simple use case:
<script type="text/javascript">
$(function() {
$("#draggable").draggable();
});
</script>
<div id="draggable" class="ui-widget-content">
<p>Drag me around</p>
</div>
Online Demo Created.
See this please.
Other Option:
JQuery Drag & Drop Plugin.
精彩评论