Re: Strtodate() bug?
| From: | Philip Hallstrom | Date: | Mon, 03 Apr 2006 20:11:38 +0000 |
| Subject: | Re: Strtodate() bug? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-233148@lists.php.net to get a copy of this message | ||
I've got some weird behavior using PHP 4.3.9. I use the function of strtotime("last Sunday"); and it's returning the timestamp for last Saturday. However, if I use strtotime("-1 day"); (I'm running this program on a Monday) it returns the correct timestamp for Sunday. Is this a bug in PHP 4.3.9?Probably. 5.1.2 says: $x = strtotime("last Sunday"); print ( date('r', $x) ); Sun, 02 Apr 2006 00:00:00 -0800 4.3.9 is *really* old. -philip