Skip th rows and get :first from rows with td
I am using the CodeIgniter HTML Table class to render a table straight out of the database. The tables are rendered accordingly:
-
<table>
<tr><th>header<th></tr>
<tr><td>row data<td></tr>
<!--and more rows just like the one immediately above-->
<table>
What I am attempting to do is hide every table row except the first one with the th tags and the one immediately below it.
I have tried:
-
$(function(){
$("#measurements tr td").hide();
});
Which hides them but at the cell level. Still no way to show the second row (Well at least from my limited perspective.)
What I would like to do is use a filter:
-
$("#measurements tr").filter("td").hide();
Obviously, that is wrong. Can someone please enlighten me here?
Thanks!