You are here: Re: displaying pre-1970 dates « PHP Programming Language « IT news, forums, messages
Re: displaying pre-1970 dates

Posted by Chuck Anderson on 02/04/06 21:51

Bosconian wrote:

>I must be having a brain freeze because I can't figure out how to display
>dates older than 1970.
>
>I have birth dates stored in MySQL as "date" data types (exp. 1955-04-06).
>I'd like to display as "April 4, 1955".
>
>I've tried using date("F j, Y"), but only get "December 31, 1969".
>
>I'm using PHP 4.3.8. Any suggestions would be appreciated.
>
>
>
>
$months = array('', 'January', 'February', 'March', 'April', 'May',
'June', 'July', 'August', 'September', 'October', 'November', 'December');

Separate year, month and day with strtok or explode and format it yourself.

--
*****************************
Chuck Anderson • Boulder, CO
http://www.CycleTourist.com
Integrity is obvious.
The lack of it is common.
*****************************

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация