php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #37282 Request to change mktime parameter order
Submitted: 2006-05-02 18:44 UTC Modified: 2006-05-03 10:27 UTC
From: caluml at gmail dot com Assigned:
Status: Wont fix Package: Feature/Change Request
PHP Version: 4.4.2 OS: Linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: caluml at gmail dot com
New email:
PHP Version: OS:

 

 [2006-05-02 18:44 UTC] caluml at gmail dot com
Description:
------------
Please can we get the mktime function accepting its parameters in a "standard" order?

Either small to big, or big to small, but something consistent.


It's insane as it is.


I did check to see if this had been reported, and couldn't find anything, so apologies if it has been.

Reproduce code:
---------------
print date("Y-m-d H:i:s", mktime(06,05,04,03,02,01) );


Expected result:
----------------
I expect to see either:

2006-05-04 03:02:01
or
2001-02-03 04:05:06

Actual result:
--------------
I see this:
2001-03-02 06:05:04

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-05-03 08:22 UTC] derick@php.net
Remember how many scripts this will break if we change it... so we won't change it.
 [2006-05-03 10:27 UTC] caluml at gmail dot com
I know that lots of scripts will break. But sometimes (global variables) it's necessary to break a few eggs to make an omelette.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Jun 02 01:01:29 2024 UTC