note 16949 deleted from function.strtotime by philip

From: Date: Wed, 21 Nov 2001 23:48:00 +0000
Subject: note 16949 deleted from function.strtotime by philip
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-21130@lists.php.net to get a copy of this message
This seems to work very well for converting a special date-string into timestamp:<br> $date_string = date ("m/d/Y H:i:s"); $date_string = strtotime ($date_string); echo $date_string.""; echo time();<br> You actually get the same value. You only have to use the format "mm/dd/yyyy hh:mm:ss". So, now you can use something like: $date_string = date ("m/d/Y 20:30:00"); to check for example something every night at 20:30. ;o)

« previous php.notes (#21130) next »