I've made a DateTime object using
$currtime = DateTime::createFromFormat("YmdHi");
Is there a way to get a string or an integer, which contains, for example, 201604041825?
$currtime->modify("+2 hours");
$newtime = $currtime->format("YmdHi");
returned
$newtime = 2147483647
DateTime::format().$datetime->modify("+2 hours");and then$datetime->format("YmdHi")returned 2147483647->format('YmdHi')DateTime::createFromFormatfails without second parameter. Show you second parameter, the problem is in it.