I'm trying to create a date in this exact format:
2022-05-19T02:00:00.000+02:00
And I'm doing this:
$todayDate = new DateTime('19-05-2022', new DateTimeZone('Europe/Madrid'));
$todayDate->format(DateTime::ATOM),
But the output looks like this:
2022-05-19T00:00:00+02:00
There's a subtle difference:
2022-05-19T02:00:00.000+02:00 <-- wanted
2022-05-19T00:00:00+02:00 <-- the one I got
Any way I can get the one I need? What format would that be?