Toggle rows by cell based class-name
Toggle rows by cell based class-name
Hi there,
may I ask how it is possible to toggle to visibility of each row, based on a class, which is added to a single cell.
So once using the "toggle"-button, only those rows (in the following example row 1&4) should be displayed.
In case this would be additional to the given text-filter-element, this would be great!
<table id="dataTables">
<thead>
<th>Col 1</th>
<th>Col 2</th>
<th>Col 3</th>
</thead>
<tbody>
<tr>
<td class="highlight">Content</td>
<td>Content</td>
<td>Content</td>
</tr>
<tr>
<td>Content</td>
<td>Content</td>
<td>Content</td>
</tr>
<tr>
<td>Content</td>
<td>Content</td>
<td>Content</td>
</tr>
<tr>
<td>Content</td>
<td class="highlight">Content</td>
<td>Content</td>
</tr>
</tbody>
</table>
The toggle-Button could also be a SELECT-element, which contains the class name. The class name itself can occur within each column.
Any solution for this?
Thank you in advance & Regards
Answers
Any ideas?