Skip to content

Instantly share code, notes, and snippets.

@mrsweaters
Created November 15, 2011 00:38
Show Gist options
  • Save mrsweaters/1365710 to your computer and use it in GitHub Desktop.
Save mrsweaters/1365710 to your computer and use it in GitHub Desktop.
Cancel sort on elements with certain class
$('ul').sortable({
start: function(event, ui) {
if ($(ui).hasClass('header')) {
$(this).sortable('cancel')
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment