php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #11820 Error in parsing switch...
Submitted: 2001-07-01 04:42 UTC Modified: 2001-07-01 07:00 UTC
From: key at mail dot ru Assigned:
Status: Not a bug Package: Unknown/Other Function
PHP Version: 4.0.5 OS: WIN98
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 you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: key at mail dot ru
New email:
PHP Version: OS:

 

 [2001-07-01 04:42 UTC] key at mail dot ru
switch (0)
{
case 01: echo "1Shit";
          break;
case 02: echo "2Shit";
          break;
case 03: echo "3Shit";
          break;
case 04: echo "4Shit";
          break;
case 05: echo "5Shit";
          break;
case 06: echo "6Shit";
          break;
case 07: echo "7Shit";
          break;
case 08: echo "8Shit";
          break;
case 09: echo "9Shit";
          break;
case 10: echo "8Shit";
          break;
}

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-07-01 07:00 UTC] derick@php.net
Not a bug, if you use a 0 before a number, it is treated like an octal number.
08 and 09 are not valid in the octal system. Just use 8 and 9 and it will work fine.

Derick
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed May 07 15:01:31 2025 UTC