So I want to get our current date today (m-d-Y) then add 30 days. I would put this in a mySQL database. Then each day it will say how many days left when it is close to 14 days.
$today = strtotime(date('Y-m-d H:i:s'));
$expireDay = date('m-d-Y', strtotime("+30 days"));
$timeToEnd = $expireDay - $today;
if ($timeToEnd <= strtotime("$expireDay - 14 days")// this is not correct syntax
{
echo "less than 14 days";
echo $timeToEnd('d')//here is where I am having problems with my syntax
} else {
echo "more than 14 days";
}