note 8729 added to date

From: Date: Tue, 26 Sep 2000 06:08:44 +0000
Subject: note 8729 added to date
Groups: php.notes 
Request: Send a blank email to php-notes+get-5366@lists.php.net to get a copy of this message
I am surprised to find that some people are still emailing me about mu post from 01-Oct-1999 09:40. Here is the basic issue: when using php to insert a date into mysql, it goes in as 'YYYYMMDD'. When you pull it back out, you get hyphens 'YYYY-MM-DD'. Moral of the story; don't automatically assume that the date will be in the same format when it comes out of the database as it was when you put it in. Screwed up, I know, but try a few echo statements and you will see what I mean. http://www.php.net/manual/function.date.php

« previous php.notes (#5366) next »