strtotime

From: Date: Thu, 14 Jan 2010 18:14:26 +0000
Subject: strtotime
Groups: php.general 
Request: Send a blank email to php-general+get-301107@lists.php.net to get a copy of this message
Hello, In a mysql date() field, I set the default to "0000-00-00". Therefore, $mydata->birthday = "0000-00-00"; But when I run this next line, $then = 1969. $then=date("Y", strtotime($mydata->birthday)); Why 1969, and not 0 or nothing? If I echo strtotime("0000-00-00"); Nothing appears. So $then should be nothing? What is wrong with my logic? Thanks, John

« previous php.general (#301107) next »