separate time from datetime in php code example
Example 1: php extract time from datetime
$time = '2013-01-22 10:45:45';
echo $time = date("H:i:s",strtotime($time));
Example 2: separate date from datetime php
date('Y-m-d', strtotime( '2015-04-16 15:00:01' ) );