RE: parsing objects

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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:neuhauser@xxxxxxxxxx]
Sent: Friday, December 22, 2006 12:18 AM
To: Marcus
Cc: php-general@xxxxxxxxxxxxx
Subject: Re:  parsing objects


# manager@xxxxxxxxxx / 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


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux