|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #18424 results of gmdate("U") and date("U") are not different!
Submitted: 2002-07-18 17:11 UTC Modified: 2002-07-18 17:15 UTC
From: kirill_sobaka_mail at rambler dot ru Assigned:
Status: Not a bug Package: Date/time related
PHP Version: 4.2.1 OS: Win32
Private report: No CVE-ID: None
 [2002-07-18 17:11 UTC] kirill_sobaka_mail at rambler dot ru

PHP Script:
#the 1 part
echo gmdate("H:i d/m/Y") . "\n";
echo date("H:i d/m/Y") . "\n";

#the 2 part
echo gmdate("U") . "\n";
echo date("U") . "\n";

please, try it! and you will see, that results in the 2 part not different! Why?


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-07-18 17:15 UTC]
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at and the instructions on how to report
a bug at

From the manual: #

U - seconds since the Unix Epoch (January 1 1970 00:00:00 GMT)

That means U always takes the time zone into account.

PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed May 22 17:01:32 2024 UTC