tags:

views:

23

answers:

1

Hello,

How do I set the $().sortable(); to a specific area to drag the entire object on? For instance, i want the user to only drag the object by holding on the area of the object.

this is my JS:

$('ul.droptrue').sortable({
            connectWith: 'ul'
});

here's my html

<ul class="droptrue">
   <li>
       <span>Title</span>
       <div>Body</div>
   </li>
</ul>
A: 

Like this:

$('ul.droptrue').sortable({
    connectWith: 'ul',
    handle: 'span'
});

You should read the documentation.

SLaks