I have a simple HTML table, where first "td" is customized to be an ID input checkbox :
<table class="table" id="mytable">
<thead>
<tr>
<th scope="col">Col1</th>
<th scope="col">Col2</th>
<th scope="col">Col3</th>
</tr>
</thead>
<tbody>
<tr>
<td><input type=checkbox name="id-1" value=1></td>
<td class="id">ID</td>
<td class="name>NAME</td>
</tr>
<tr>
<td><input type=checkbox name="id-2" value=2></td>
<td class="id">ID</td>
<td class="name>NAME</td>
</tr>
....... A lot of more rows, some already checked ..........
</tbody>
</table>
Then I am using Jquery Datatable to "enhance" the table to be a Datatable :
$('#mytable').DataTable();
Since some values could be already checked during table rendering, I'm trying to figure out the most effective way to add a "show only selected/show all" button that filters the datatable and only show checked checkbox.
Is there a way to do it directly with Datatable without involving external code or what's the best way to achieve this?
I read about a legacy extension named "TableTools" that should ease this, but it seems being deprecated from a long time.