2
In a hypothetical situation with a datatable
, asynchronously will be made a swith
of ativo/inativo
for the record.
I must create a form for each row/record of this datatable? Is it semantically incorrect? Or should I manipulate the data through ids
, data attributes
, etc.... ?
To illustrate this situation, it would be something like:
<table>
<thead>
<th>
<td>Nome</td>
<td>Ativo</td>
</th>
</thead>
<tbody>
<form id="1">
<tr>
<td>Fulano</td>
<td>
<input type="checkbox" name="ativo">
</td>
</tr>
</form>
<form id="2">
<tr>
<td>Cicrano</td>
<td>
<input type="checkbox" name="ativo">
</td>
</tr>
</form>
</tbody>
</table>
that I know you can create your table within a form, do not need to separate everything
– Sarah