I have select and input button control inside loop. Initially input button is hidden with css property display:none; I want to show input button when select value gets change with the help of jquery. Only respective input should be visible not all. Please help me out
<td>
<select id="isactive" class="select_<?php echo($i++);?>">
<option value="single" <?php if($currentStatus == "S") echo("selected=\"true\""); ?> >Single</option>
<option value="double" <?php if($currentStatus == "D") echo("selected=\"true\""); ?>>Double</option>
<option value="no" <?php if($currentStatus == "N") echo("selected=\"true\""); ?>>No</option>
</select>
<input type="button" class="updatebtn" id="updateoptinbtn_<?php echo($j++);?>" value="Update" />
</td>
JQuery
$(".select").change(function(){
$("#updateoptinbtn").show();
});
Try
.closest()and.find()