note 9150 added to strtotime

From: Date: Wed, 18 Oct 2000 22:26:33 +0000
Subject: note 9150 added to strtotime
Groups: php.notes 
Request: Send a blank email to php-notes+get-6678@lists.php.net to get a copy of this message
This function appears to only accept dates American style MM/DD/YYYY, I have had to convert from my DD/MM/YYYY for it to work, you can do it with something like this: $date = strtotime(substr($date,5,2) . '/' . substr($date,8,2) . '/' . substr($date,0,4) . ' ' . substr($date,11,5)); (The last one (11,5) puts on the time (i.e. DD/MM/YYYY HH:MM) http://www.php.net/manual/function.strtotime.php

« previous php.notes (#6678) next »