<script src = js/jquery-1.10.min.js> </script> <link rel = styleSheet href = public/css/jquery-ui.min.css> <script src = js/jquery-ui.min .js> </script>2. Attach the sortable class to the element
<tBody class = sortable> <tr> </tr> </tr> </tbody>3. Open and configure
$ (Function () {$ (. Sortable) .sortable ({Cursor: Move, Items: TR, // Just when TR can drag OPACITY: 0.6, // At that time, add animation update: function (event, ui) {// After updating sorting, varcategoryids = $ (this) .sortable (toarray); var $ this = $ (this);}}); $ (. Sortable). disableselect ();});
The above is the HTML Table mouse dragging sorting function introduced by Xiaobian. I hope it will be helpful to everyone. If you have any questions, please leave me a message. Xiaobian will reply to everyone in time. Thank you very much for your support for the VEVB Wulin website!