How to get time or date in a datetime format variable

T

Tùng Nguyễn

Guest
I have a variable like this

$string = '2019-10-07T19:00:00+07:00';


it is in ISO8601 format date time. how can I get the date or the time only?

or does any method to convert this into another format?

like:

$str = '2019-10-07'


Thank you for your help!

Continue reading...
 
Top