I need to output that as

Category:  XXXXX

   Sub-category:  yyyy1
   Sub-category: yyyy2

..
..

linking by id's to parent id's just like in a database.



-----Original Message-----
From: Roman Neuhauser [mailto:[EMAIL PROTECTED]
Sent: Friday, December 22, 2006 12:18 AM
To: Marcus
Cc: php-general@lists.php.net
Subject: Re: [PHP] parsing objects


# [EMAIL PROTECTED] / 2006-12-21 18:06:28 +0200:
> Hello
>
> I have a soap call that returns something like;
>
> Result from a print_r();
>
> stdClass Object ( [getCategoryTreeReturn] => Array ( [0] => stdClass
Object
> ( [iId] => 1 [sName] => Cars & Motorbikes [iParentId] => 0 [iTreeCount] =>
> 114302 [iLocalCount] => 0 [aSubCats] => Array ( [0] => stdClass Object (
> [iId] => 2 [sName] => Car Electronics [iParentId] => 1 [iTreeCount] => 0
> [iLocalCount] => 0 ) [1] => stdClass Object ( [iId] => 5 [sName] => Car
> Accessories [iParentId] => 1 [iTreeCount] => 57160 [iLocalCount] =>
57142 )
> [2] => stdClass Object ( [iId] => 16 [sName] => Motorcycles [iParentId] =>
1
> [iTreeCount] => 11 [iLocalCount] => 0 )
>
> I need to convert that to a multidimensional array to link ID's to Parent
> ID's.

What makes you think so?

--
How many Vietnam vets does it take to screw in a light bulb?
You don't know, man.  You don't KNOW.
Cause you weren't THERE.             http://bash.org/?255991

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to