note 64865 deleted from function.array-shift by bjori
| From: | bjori@php.net | Date: | Sat, 22 Apr 2006 10:16:16 +0000 |
| Subject: | note 64865 deleted from function.array-shift by bjori | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-109002@lists.php.net to get a copy of this message | ||
Note Submitter: haroon at fastcreators dot com
Reason: useless
----
you can also use shift_array to extract a sub-array from main array, like sometimes are getting
array of arrays.
say you have array A and array B in a parent array C then to extract A and B individually you can
perform action like
$takeAfromC = array_shift(C)
$takeBfromC = array_shift(C)
now you have contents of array A in "$takeAfromC" and contents of array B in
"$takeBfromC" and you can use it easily this method helped me a lot in writing scripts for
importing contact list from gmail, yahoo, AOL, hotmail and MSN contact lists to parse the cURL
results.....