I need a way to deactivate form elements in the second and third columns, starting from the second row until the nth row using a jQuery selector.
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet"/>
<table class="table table-striped">
<thead>
<tr class="warning">
<th>column1</th>
<th>column2</th>
<th>column3</th>
</tr>
</thead>
<tbody>
<tr>
<td>500.00</td>
<td>
<select class="form-control" id="ddcards">
<option selected>Select Card</option>
<option>CC0</option>
<option>CC1</option>
<option>CC2</option>
</select>
</td>
<td>
<input type="submit" class="btn btn-primary" id="btnSubmit" value="submit">
</td>
</tr>
<tr>
<td>500.00</td>
<td>
<select class="form-control" id="ddcards">
<option selected>Select Card</option>
<option>CC0</option>
<option>CC1</option>
<option>CC2</option>
</select>
</td>
<td>
<input type="submit" class="btn btn-primary" id="btnSubmit" value="submit">
</td>
</tr>
<tr>
<td>500.00</td>
<td>
<select class="form-control" id="ddcards">
<option selected>Select Card</option>
<option>CC0</option>
<option>CC1</option>
<option>CC2</option>
</select>
</td>
<td>
<input type="submit" class="btn btn-primary" id="btnSubmit" value="submit">
</td>
</tr>
</tbody>
</table>
Here is an example of the desired layout:
The goal is to disable rows with form elements in the specified columns up to the nth row.
An important requirement is that when button 1 is clicked, it enables the second row, then when the second button is clicked, it enables the third row, and so on...