Yet one more checkable desk jQuery plugin that permits customers to pick and unselect one or a number of rows in an HTML desk utilizing a checkbox record.
The plugin shops all choices in an array and shows comma-separated row IDs in an enter field as a number of rows are chosen.
Learn how to use it:
1. Add checkboxes and distinctive identifiers to every row of the desk.
<tbody> <tr> <td> <enter class="select-row" data-rows-group-id="customers" kind="checkbox" id="123" data-id="123" /> </td> <td> ... </td> ... </tr> <tr> <td> <enter class="select-row" data-rows-group-id="customers" kind="checkbox" id="456" data-id="456" /> </td> <td> ... </td> ... </tr> ... </tbody>
2. Add a ‘Verify All’ checkbox to the desk header.
<thead> <th> <enter class="select-all" data-input-id="ids" data-rows-group-id="customers" kind="checkbox"> </th> <th> ... </th> ... </thead>
3. Create an enter area to carry the IDs of the chosen rows.
<script src="/path/to/cdn/jquery.slim.min.js"></script> <script src="/path/to/selectrows.min.js"></script>
4. Initialize the plugin and finished.
selectRowsJs.init();
This superior jQuery plugin is developed by leandrosardi. For extra Superior Usages, please test the demo web page or go to the official web site.