[PHP] Help with Reverse Tree Traversal using Recursion ..

2005-11-14 Thread Greg Schnippel
I have a large data tree that I wanted to display in an outline format. I used a textbook tree recursion function to go through the data and display it as nested unordered lists: function outputTree($id) { if (checkChildObjectExists($id)) { print ul; $child =

Re: [PHP] Help with Reverse Tree Traversal using Recursion ..

2005-11-14 Thread Richard Lynch
On Mon, November 14, 2005 7:46 am, Greg Schnippel wrote: I have a large data tree that I wanted to display in an outline format. I used a textbook tree recursion function to go through the data and display it as nested unordered lists: function outputTree($id) { if

Re: [PHP] Help with Reverse Tree Traversal using Recursion ..

2005-11-14 Thread Greg Schnippel
Richard - Thanks for the helpful suggestion but that won't resolve my problem the way I currently have it written because I'm creating a new, nested ul each time I loop through: print ul; foreach ($parent as $key = $value) { ... } print /ul; So when I tried this, the output was still inverted