I want a function in php that will return a date in following format
2017-01-25T08:55:40.000Z
I tried following
$obj->format(DateTime::ATOM); // output-> 2017-01-25T00:00:00+0100
$obj->format(DateTime::ISO8601); // output-> 2017-01-25T00:00:00+0100
I am not getting any solution for this in PHP - I am able to get this format in javascript using moment.js but not in PHP.