Answers for "get time from datetime php"

PHP
2

php current time

echo date('Y-m-d H:i:s');

//Output something like this:
//2021-07-30 10:07:45
Posted by: Guest on July-30-2021
1

php extract time from datetime

$time = '2013-01-22 10:45:45';

echo $time = date("H:i:s",strtotime($time));
Posted by: Guest on July-01-2020

Code answers related to "get time from datetime php"

Browse Popular Code Answers by Language