php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #2345 overloads, incompatibility with php2
Submitted: 1999-09-21 17:38 UTC Modified: 2000-08-06 06:11 UTC
From: krauss at b2b dot com dot br Assigned:
Status: Closed Package: Compile Failure
PHP Version: 3.0.11 OS: Linux (2.0.36)
Private report: No CVE-ID: None
 [1999-09-21 17:38 UTC] krauss at b2b dot com dot br
The overload, 

$x=1; $x[0]="a"; $x[1]="b"; 

is valid in PHP2 (and Perl), but not in PHP3 (3.0.11).
Message:
Warning: Illegal string index in /... on line ...
(when $x is from cookie)
or
Warning: Variable $x is not an array or string in /... on line ...

I had problemens with $x from a SetCookie and $x[$i] in script attribs.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-08-06 06:11 UTC] rasmus@php.net
Known issue - not much we can do about this at this point.  Perhaps in PHP 4.1 we will have some sort of workaround for this.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue May 14 13:01:33 2024 UTC