me102 Posted July 15, 2007 Share Posted July 15, 2007 I made a little billing system but ran into a big problem how to find out the next month using the date() I have tryed everything. Can someone link me to a tut or tell me how to do this? ??? ??? ??? Quote Link to comment Share on other sites More sharing options...
pocobueno1388 Posted July 15, 2007 Share Posted July 15, 2007 <?php $next_month = date ('m', strtotime ("$date + 1 month")); echo $next_month; ?> Is that what your looking for? Quote Link to comment Share on other sites More sharing options...
me102 Posted July 15, 2007 Author Share Posted July 15, 2007 Yes that what I was looking for but I need it to come out to be 2007-08-14 Quote Link to comment Share on other sites More sharing options...
pocobueno1388 Posted July 15, 2007 Share Posted July 15, 2007 Just change it to: <?php $next_month = date ('Y-m-d', strtotime ("$date + 1 month")); echo $next_month; ?> Quote Link to comment Share on other sites More sharing options...
me102 Posted July 15, 2007 Author Share Posted July 15, 2007 Thanks so much. 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.