function datevalidation($value) { // value should be year-month-day $today = strtotime(date(Ymd)); $value = strtotime($value); if ($value >= $today) { return true; } else { return false; } }