I’ve getting a DATETIME from the database and I need to be able to check to see whether or not that date is within 30 days from now.
$renewal_date = $row['renewal_date'];
$current_time = new DateTime();
$interval = $renewal_date->diff($current_time);
That ain’t workin’ for me.
Try something like this
Remove the && condition if you want to show renewal for dates in the past