|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #18921 integer values 08, 09 convert to string as 0
Submitted: 2002-08-15 13:54 UTC Modified: 2002-08-15 13:59 UTC
From: ben at parcelrecords dot com Assigned:
Status: Not a bug Package: Strings related
PHP Version: 4.2.2 OS: Windows 2000
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.
Block user comment
Status: Assign to:
Bug Type:
From: ben at parcelrecords dot com
New email:
PHP Version: OS:


 [2002-08-15 13:54 UTC] ben at parcelrecords dot com
<? echo 01, 02, 03, 04, 05, 06, 07, 08, 09, 10; ?>
instead of

8 and 9 are now zeroes


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-08-15 13:59 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

integers that begin with leading zeros are treated as octal numbers.  Since 08 and 09 contain digits which are invalid in the octal base, they're reduced to zeros.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Jul 16 07:01:31 2024 UTC