ShootingBlanks Posted November 16, 2007 Share Posted November 16, 2007 How do I amend this statement to make it so that the variable $newDate is 2-years later than today's current date?: <?php $newDate = date('Y-m-d'); ?> I tried: $newDate = (date('Y-m-d') + 730); But that didn't work. Thanks! Quote Link to comment Share on other sites More sharing options...
pocobueno1388 Posted November 16, 2007 Share Posted November 16, 2007 <?php $twoYear = date('Y-m-d', strtotime ("+ 2 year")); echo $twoYear; ?> Quote Link to comment Share on other sites More sharing options...
ShootingBlanks Posted November 16, 2007 Author Share Posted November 16, 2007 Perfect - thanks! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.