Re: Array question
| From: | Maxim Maletsky | Date: | Fri, 08 Nov 2002 14:52:07 +0000 |
| Subject: | Re: Array question | ||
| References: | 1 2 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-23138@lists.php.net to get a copy of this message | ||
to precise:
$array = Array('name'=>'Maxim',
'surname'=>'Maletsky');
unset($array['name']);
// now array has this structure:
// Array('surname'=>'Maletsky')
--
Maxim Maletsky
maxim@php.net
Jason Wong <phplist@gremlins.com.hk> wrote... :
> On Friday 08 November 2002 17:25, nikos wrote:
> > Does anybody know how to remove an item from an array?
> > Let's say
> >
> > $array('banna', 'apple','cherry')
> > foreach ($array as $value) {
> > if ($value=='chery') DELETE $value FROM $array
> > ...
>
> unset().
>
>
> --
> Jason Wong -> Gremlins Associates -> www.gremlins.com.hk
> Open Source Software Systems Integrators
> * Web Design & Hosting * Internet & Intranet Applications Development *
>
>
> /*
> Kiss me, Kate, we will be married o' Sunday.
> -- William Shakespeare, "The Taming of the Shrew"
> */
>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>