gnawz Posted July 22, 2009 Share Posted July 22, 2009 Hi guys? Help me on how I can change the format of my date displayed form a MySQL database If for instance I have a variable for my date like echo $dateregistered; ie Default is: YY-MM-DD eg 2009-05-23 How do I make it display like this DD-MM-YY or DD-MM.YYY eg 23-05-2009 0r 23-05-09 Kindly help Quote Link to comment Share on other sites More sharing options...
waynewex Posted July 22, 2009 Share Posted July 22, 2009 $new_date_formate = date("d-m-Y",strtotime($row['date_col'])); 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.