troubleshooting Question

How do I convert a date/time string of the form yyyy-m-d h:m:s to d mmm yyyy h:m in PHP

Avatar of mike99c
mike99c asked on
PHP
6 Comments1 Solution10 ViewsLast Modified:
I have a date/time string in PHP of the form:
yyyy-m-d h:m:s
For example 2021-6-30 14:30:00
In think this is in MySQL date/time format.

I wish to convert this to a more user friendly format of: 30 June 2021 14:30.

Can you please let me know how I can do this using PHP date/time functions rather than string functions. I would like the month to be language sensitive so the language needs to be passed in.
ASKER CERTIFIED SOLUTION
Cyril Joudieh
Founder, Software Engineer, Data Scientist

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 6 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 6 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros