Im using jquery UI sorting list to allow my users to select and order two lists and to change items between them.
If you are not familiar with jquery sorting, the actual code is very simple:
Html
<ul id="sortable1" class="connectedSortable">
<li class="ui-state-default">Item 1</li>
<li class="ui-state-default">Item 2</li>
<li class="ui-state-default">Item 3</li>
</ul>
<ul id="sortable2" class="connectedSortable">
<li class="ui-state-highlight">Item 1</li>
<li class="ui-state-highlight">Item 2</li>
<li class="ui-state-highlight">Item 3</li>
</ul>
JS
$(function() {
$( "#sortable1, #sortable2" ).sortable({
connectWith: ".connectedSortable"
}).disableSelection();
});
You can try it here: http://jsfiddle.net/9jQKu/
My problem is, if you empty one of the list dragging all the elements to the other one, you actually loose that column and you will not be able to return an item to the empty column.
How can I fix this?
ps. Also, why is not responding to the cursor:hand style?
cursor:handis IE-specific. Usecursor:pointerinstead.