- mktime: documentation ( source)
- date: documentation ( source)
- strtotime: documentation ( source)
<?php
$test_date = date("d/m/Y", mktime(0, 0, 0, 2, 8, 2012)); //"08/02/2012";
$todays_date = date("d/m/Y");
echo $test_date. " " .$todays_date;
if (strtotime($test_date) < strtotime($todays_date))
{
echo "Past";
}
else
{
echo "Future";
}
?>