I am getting ISO datetime using below code
$date= date("c");
echo $date;
which returns something like below
2016-01-07T20:18:46+00:00
But the API I use tells that its wrong format and it needs in below format:
2016-01-07T20:35:06+00Z
I need to remove :00
at the end and add Z
.
I am completely new to regex , can anyone help me understand the regex and tell which format is required.