Re: Date-class
| From: | Stig S. Bakken | Date: | Sat, 21 Jul 2001 21:58:24 +0000 |
| Subject: | Re: Date-class | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-935@lists.php.net to get a copy of this message | ||
Erik Hjortsberg wrote:
>
> At 02:20 2001-07-19 +0200, you wrote:
> >Handy. How do you deal with timezones? To comply more with other
> >classes, the "asXxx" methods should be renamed to "toXxx" (we havre
> >toString in a bunch of places, inspired by Java)
> >
> >The date comparison function should return -1/0/1 so it cab be used with
> >sorting.
>
> Hmm, I'm not sure how to handle timezones. Do you mean one should specify
> the timezone directly?
You should at least specify what timezone the timestamp is in, since
people may use the unixtime with functions like date() or gmdate(). I
would make it default to GMT, less hassle. :-)
- Stig