Re: note 8144 added to array
| From: | Hartmut Holzgraefe | Date: | Tue, 29 Aug 2000 13:13:24 +0000 |
| Subject: | Re: note 8144 added to array | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-3582@lists.php.net to get a copy of this message | ||
mike@newtradesmen.com wrote:
>
> By the way, calling array() and then adding associative data into the array causes the array to
> store garbage data in the array.
> function foo(){
> $value = "bar";
> $arr = array();
> $arr["key"] = $value;
> foreach(array_keys($arr) as $s)
> {
> printf($s);
> }
> }
> You might be surprised what you get, I know I was.
>
well, i got "key", as expected. no suprise at all :(
what did you get?
--
Hartmut Holzgraefe
hartmut@six.de http://www.six.de +49-711-99091-77 fax:-99