This question already has an answer here:
- Convert one date format into another in PHP 15 answers
I have a time as 5:4 pm
and i want convert the time from AM/PM to 24 hour format in PHP, i try as date('H:i',strtotime('5:4 pm'))
but this don't work and result is 16:00
in the event that it should be 17:04
. what do i do?
DEMO: http://sandbox.onlinephpfunctions.com/code/bfd524f65ea4fa3031e55c9879aab711f31e1b37
I can not change this time.
</div>