<?php
while($row = mysqli_fetch_array($result)){
?>
<tr>
<td>
<input type="checkbox"
id="<?php echo $row['invoice_id']; ?>"
name="invoice_id[]"
rel="<?php echo $row['due_date']; ?>"
value="<?php echo $row['invoice_id'];?>">
</td>
<td><?php echo $row['invoice_no']; ?></td>
<td><?php echo $row['due_date']; ?></td>
</tr>
<?php
}
?>
my question is how to disable all check box which is not equal to due date of the first check box checked
example
invoice_no due_date
1 10-15-2014
2 10-15-2014
3 10-16-2014
4 10-17-2014
if i checked invoice_no 1, invoice_no 3 and 4 will be disabled and if i unchecked invoice_no 1, all check_box will be enabled
as of now i only have this and don't know whats next thing to do, i search the web but still i cant find how to do this
$("input[type=checkbox]").change(function() {
$due_date = $(this).attr("rel");
});
TIA for your help.....