echo preg_replace('/^.*(\d{2})(\d{2})(\d{2})$/', '$1:$2:$3', $string);
It seems to me that this line has a certain format, which should be analyzed for data. Something like:
sscanf($string, '%u-%3s-%u-%u-%u', $id, $type, $num, $foo, $timestamp); $timestamp = strtotime($timestamp); echo date('Ymd H:i:s', $timestamp);
deceze
source share