php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #1501 date() wackiness?
Submitted: 1999-06-07 14:11 UTC Modified: 1999-06-07 14:28 UTC
From: mute at snip dot net Assigned:
Status: Closed Package: Misbehaving function
PHP Version: 3.0.9 OS: linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: mute at snip dot net
New email:
PHP Version: OS:

 

 [1999-06-07 14:11 UTC] mute at snip dot net
Just compiled 3.0.9, had heard of some possible issues with date() but was doing some stuff on my own.

The following:
echo date("F",mktime(0,0,0,1,0,0));
Returns:
"December"

When it should return "January"


Upon looking at the manual online i saw the example of:

$epoch = date ("D F dS...",mktime(0,0,0,0,0,0));
echo $epoch;
Which is supposed to return: "Wed December 31st 1969..."

On my system it returns: "Wed December 31st..."

Sorry if this has been mentioned im new to all of this :)

-kyle

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1999-06-07 14:28 UTC] andrey at cvs dot php dot net
echo date("F",mktime(0,0,0,1,0,0));

day passed should not be 0, but rather in the range 1-31
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Thu Oct 08 10:00:01 2026 UTC