|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #8495 Bug #6818 continued
Submitted: 2000-12-30 13:51 UTC Modified: 2001-01-30 05:04 UTC
From: mark at dreamzpace dot com Assigned:
Status: Not a bug Package: Variables related
PHP Version: 4.0.4 OS: Linux Redhat 6.1
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: mark at dreamzpace dot com
New email:
PHP Version: OS:


 [2000-12-30 13:51 UTC] mark at dreamzpace dot com
In response to (the closed) bug #6818 (I can't reopen it):

Using === instead of == is not a solution in my opinion:
- it's not compatible with older code (php3)
- it's still a bug: comparing a variable with value 0 with a string should always return 'false', regardless the type.


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2001-01-09 10:27 UTC]
Could you please describe your problem and give an example
of faulty code?
 [2001-01-10 14:43 UTC] mark at dreamzpace dot com
Taken from bug 6818:


$variable = 0;

if ($variable == "some_string")
  print "This must be a bug?! Variable set as $variable.\n\n<br>";
  if ($variable != "some_string")
    print "But with variable set as $variable it works fine.\n\n";
  print "This works as I expected.\n\n";

 [2001-01-30 05:04 UTC]
This is not a bug.


PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Jul 21 20:01:30 2024 UTC