Re: 4.0.2 Release
| From: | chrisv at b0rked dot dhs dot org | Date: | Thu, 24 Aug 2000 19:43:05 +0000 |
| Subject: | Re: 4.0.2 Release | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-30558@lists.php.net to get a copy of this message | ||
>
> > > What *should* happen is the second array item (b) should disappear. What
> > > *does* happen is that $dope[1] is unset, AND the index is reduced, but the
> > > item isn't deleted. So your array now goes "a", (blank),
> > > "c", "d". Both
> > > "b" and "e" were lost.
> > PHP always uses associative arrays -- so performing unset() on an array
> > index leaves you with the proper number of elements. Your array just no
> > longer contans the key 1 when you do the above.
>
> well that was he was worried about, that this did *not* happen
> the way you described
>
I never said it adjusted the keys. I only said that the array no longer
contained the associated key -- thereby leaving a hole in the array where
the key was.
Chris