|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #55619 checkdate() returns incorrect results
Submitted: 2011-09-06 11:33 UTC Modified: 2011-09-06 12:03 UTC
From: invisiblexman2010 at gmail dot com Assigned:
Status: Not a bug Package: Date/time related
PHP Version: 5.3.2 OS: linux 2.6.32-33-generic on i686
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 this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Bug Type:
From: invisiblexman2010 at gmail dot com
New email:
PHP Version: OS:


 [2011-09-06 11:33 UTC] invisiblexman2010 at gmail dot com
Function checkdate() returns incorrect results in some cases, when passed February 29 leap year.

Test script:
var_dump(checkdate('02', '29', '2100'));
var_dump(checkdate('02', '29', '1900'));

Expected result:
bool(true) bool(true)

Actual result:
bool(false) bool(false)


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2011-09-06 11:46 UTC] invisiblexman2010 at gmail dot com
-Summary: incorrect results +Summary: checkdate() returns incorrect results -PHP Version: Irrelevant +PHP Version: 5.3.2
 [2011-09-06 11:46 UTC] invisiblexman2010 at gmail dot com
Update Summary section
 [2011-09-06 12:03 UTC]
-Status: Open +Status: Bogus
 [2011-09-06 12:03 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

This is correct behaviour:
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Jul 24 16:01:28 2024 UTC