Reputation: 2877
echo date('Y-m-d h:m:s',strtotime('2008-11-03 16:00:29'))
Returns 2008-11-03 04:11:29
I've tried changing my default time zone and adding GMT,UTC,PTC behind the string and nothing will change the output. How do I get strtotime to match the input?
Upvotes: 1
Views: 2811
Reputation: 11696
Use 'Y-m-d H:i:s'
if you want 24-hour time, or add the am/pm to the end with 'Y-m-d h:i:s a'
Upvotes: 2