Reply to Re: displaying pre-1970 dates

Your name:

Reply:


Posted by Bosconian on 02/04/06 06:36

"Dave Kelly" <daveekelly@earthlink.net> wrote in message
news:3TVEf.10107$1n4.3142@newsread2.news.pas.earthlink.net...
> 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.
> >
> >
> This is from somebody that probably don't know what he is talking about.
>
> The manual says that 'date' is used to set the SYSTEM date and time.
>
> That should be why you are being blocked by the epoach wall. Not a
> system in the world has a last modified date of 4/4/1955.

Is it possible that you know even less?

Anyone remotely familiar with the date function knows you can pass a second
timestamp argument. I thought my previous message implied this. Shame on me.

From the docs:

string date ( string format [, int timestamp] )

Returns a string formatted according to the given format string using the
given integer timestamp or the current local time if no timestamp is given.
In other words, timestamp is optional and defaults to the value of time().

Linux-based servers support negative timestamps. I tried using strtotime,
but to no avail.

[Back to original 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

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