erasam Posted July 31, 2007 Share Posted July 31, 2007 hello, I am a php beginner. I would like to know how to change the date format in 31-JUL-2007 to 07-31-2007? Quote Link to comment https://forums.phpfreaks.com/topic/62609-solved-change-date-format/ Share on other sites More sharing options...
clearstatcache Posted July 31, 2007 Share Posted July 31, 2007 try ds ... <?php $date = date( 'm-d-Y', strtotime('31-JUL-2007') ); print "date: $date\n"; ?> Quote Link to comment https://forums.phpfreaks.com/topic/62609-solved-change-date-format/#findComment-311661 Share on other sites More sharing options...
erasam Posted July 31, 2007 Author Share Posted July 31, 2007 thx very much for your help Quote Link to comment https://forums.phpfreaks.com/topic/62609-solved-change-date-format/#findComment-311665 Share on other sites More sharing options...
clearstatcache Posted July 31, 2007 Share Posted July 31, 2007 welcum... Quote Link to comment https://forums.phpfreaks.com/topic/62609-solved-change-date-format/#findComment-311666 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.