Re: Creating an array as a property of an object

From: Date: Tue, 30 Jan 2007 00:58:23 +0000
Subject: Re: Creating an array as a property of an object
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-247984@lists.php.net to get a copy of this message
On Fri, January 26, 2007 3:09 pm, Ken Kixmoeller -- reply to ken@kixmoeller.com wrote: > I want to have an multidimensional array as a property of an object. While not relevant to your immediate question, you may want to be told that PHP arrays are not truly multi-dimensional, but nested. I.e., one cannot do: $foo[0] = 'bar'; $foo[0][] = 'baz'; $foo[0] can hold a value, or another array, but not both. This confuses some "converts" from other languages which store data differently in a "true" multi-dimensional fashion. YMMV NAIAA -- Some people have a "gift" link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So?

« previous php.general (#247984) next »