Sortable update event never fires
OK, I'm frustrated, and feel like I'm missing something obvious. Dragging and reordering works fine, but my update event never fires for the following sortable:
-
<div id="PhotoList">
<div id="l_05198fad-f1dd-43bb-a458-29358167e932" class="photoItem">
<div class="handle"><img alt="" src="ThumbHandler.ashx?fileid=05198fad-f1dd-43bb-a458-29358167e932"/></div>
</div>
<div id="l_bc1b522c-36e7-44c0-926d-7f8bdf82c580" class="photoItem">
<div class="handle"><img alt="" src="ThumbHandler.ashx?fileid=bc1b522c-36e7-44c0-926d-7f8bdf82c580"/></div>
</div>
</div>
<input type="hidden" id="SortedList" value="" />
-
$(function () {
$("#PhotoList").sortable( {
update : function () {
$("#SortedList").val($("#PhotoList").sortable("serialize"));
},
opacity: 0.7,
handle: $("#PhotoList > .photoItem > .handle")
});
});
And just to be clear, the event should fire every time I move the elements around, right?