$time = time() - (86400 * $numOfDays); ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime($time); $mon++; $year = $year + 1900;