JSHINER Posted March 23, 2007 Share Posted March 23, 2007 When I use the following: echo date("F j, Y",$i); It displays as December 31, 1969 When I do: echo "$i"; It displays correctly: 2007-03-23, or whatever the date imputted was. I have dates stored in my database as DATE format (0000-00-00) - But I want them to display as March 25, 2007. What am I doing wrong here ? Link to comment https://forums.phpfreaks.com/topic/43990-solved-my-date-displays-dec-31-1969/ Share on other sites More sharing options...
mjlogan Posted March 23, 2007 Share Posted March 23, 2007 echo date("F j, Y",strtotime($i)); Link to comment https://forums.phpfreaks.com/topic/43990-solved-my-date-displays-dec-31-1969/#findComment-213573 Share on other sites More sharing options...
JSHINER Posted March 23, 2007 Author Share Posted March 23, 2007 Thanks ! Link to comment https://forums.phpfreaks.com/topic/43990-solved-my-date-displays-dec-31-1969/#findComment-213577 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.