I have iterated a table based on my query result... I have a column lastDate
it contains a date value like 01/24/2010
... Now i have to check the date value with the current date if currentdate
is less than or equal to lastDate
i have to enable the checkbox else disable it..... Any suggestion how it can be done in php...
Here is my code
<? if(isset($comment))
{ echo '<tr><td class=table_label colspan=5>'.$comment.'</td></tr>'; } ?>
<?php foreach($getassignmentdata as $row) { ?>
<td align="center" class="table_label" id="txtsubdat">
<?
$dd=$row['dDate'];
if($dd=='')
{
}
else
{
$str = $dd;
$dd = strtotime ( $str );
echo date ( 'm/d/Y' , $dd );
} ?>
</td>
<td align="center">
<input type="checkbox" name="group" id="group"
value="<?=$row['dAssignment_id']?>" onclick="checkdisplay(this);">
</td>
<? } ?>