Why not just link straight to the tutorial on your site? ;) Not sure what your point is, other than "there's a way to do this in userland," which I cover in my email. Maybe some sentences to accompany it would make it easier to understand.
Thanks for reading. Cheers. Mike. On Fri, Dec 26, 2008 at 5:55 AM, Kevin Waterson <ke...@phpro.org> wrote: > This one time, at band camp, "Mike Panchenko" <m...@mihasya.com> wrote: > > > Hey everybody, I'm new both to the list and to hacking the internals, so > > I'll try to keep it short and humble. > > > > I've written an array_flatten function which just takes all elements from > a > > nested array and pushes them into a single indexed array. > > function flattenArray(array $array){ > $ret_array = array(); > foreach(new RecursiveIteratorIterator(new RecursiveArrayIterator($array)) > as $value) > { > $ret_array[] = $value; > } > return $ret_array; > } > > Kevin > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > >