I have a table, with a select
, in each row, and when I click a button I want to get all the items in the table where select option
has value.
<table id="myTable">
<span class="result"></span>
<thead>
<tr>
<th>Nome</th>
<th>Status</th>
<tr>
</thead>
<tbody>
<tr>
<td>xyz</td>
<td>
<select>
<option class="op" value="0">-- Selecione --</option>
<option class="op" value="1">-- Bloqueado --</option>
<option class="op" value="2">-- Ativo --</option>
</select>
</td>
</tr><tr>
<td>abc</td>
<td>
<select>
<option value="0">-- Selecione --</option>
<option value="1">-- Bloqueado --</option>
<option value="2">-- Ativo --</option>
</select>
</td>
</tr>
</tbody>
</table>
<span class="status"></span>
<button class="row" id="btnAdicionar" type="button" >Adicionar</button>
How can I get to wipe this table and pick up any items that are not 0?