3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function format_as_datetime($dt) { return substr($dt,0,4).'-'.substr($dt,4,2).'-'.substr($dt,6,2).' '.substr($dt,8,2).':'.substr($dt,10,2).':'.substr($dt,12,2); } echo strtotime(format_as_datetime("20140414221031"));
Output for 4.3.0 - 7.1.0
1397506231