Re: date/timezone classes

From: Date: Fri, 08 Jul 2005 12:31:14 +0000
Subject: Re: date/timezone classes
References: 1 2 3 4  Groups: php.internals 
Request: Send a blank email to internals+get-17194@lists.php.net to get a copy of this message
On Fri, 8 Jul 2005, Edin Kadribasic wrote: > I would love to be able to do something like this: > > $d = new Date(time()); > $d->month++; > $d->print("Y-m-d"); // date() equiv. Adding methods is no problem, that's what you get for free anyway, I just think that $d->month is too much magic, and not reproducable in non OO. (Also, passing a timestamp with time() is not always working, because of windows' limitations with it, that's the reason why I made it a string, or empty in case you want to use current time). Derick -- Derick Rethans http://derickrethans.nl | http://ez.no | http://xdebug.org

« previous php.internals (#17194) next »