|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2009-11-30 22:44 UTC] info at demonwares dot com
Description: ------------ Code returns the wrong month name Reproduce code: --------------- date( 'F', mktime(0, 0, 0, 2) ) Expected result: ---------------- This should return February Actual result: -------------- This returns March PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Dec 04 20:00:01 2025 UTC |
# php -n -d date.timezone="Europe/Helsinki" -r 'echo date("F", mktime(0, 0, 0, 2) ), "\n";' February It does return february. But if you omit the day/year, then mktime() uses the current day/year. RTFM: http://php.net/mktime