Re: strtotime question

From: Date: Sat, 10 Mar 2001 02:15:41 +0000
Subject: Re: strtotime question
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-43276@lists.php.net to get a copy of this message
0 is Sunday, 1 is Monday, 2 is Tuesday, ... -- Visit the Zend Store at http://www.zend.com/store/ Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm Volunteer a little time: http://chatmusic.com/volunteer.htm ----- Original Message ----- From: Jason Murray <jason@jwebmedia.com> Newsgroups: php.general Sent: Tuesday, March 06, 2001 12:06 PM Subject: [PHP] strtotime question > Hi there, > > $ob->date is '2000/03/06'. > > $d = ereg_replace('([0-9]*)-([0-9]*)-([0-9]*)', > '\2/\3/\1', $ob->date); > > $d is now '03/06/2000'. > > $foo = getdate(strtotime($d)+86400); > > Here I have to add an entire day to the value of strtotime($d) to get > the expected results for below. > > echo "<P>" . $foo["weekday"] . ", " . $d . "<blockquote>\n"; > > Without adding a day to strtotime() $foo["weekday"] is 'Monday'. > > Is there some kind of timezone stuff I am not accounting for? or is it > something else? > > Thanks, > Jason > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.general (#43276) next »