i m using mind body api to fetch data. i have n object that contains the following data, i need to fetch all the id firstname and lastname and store it in database. i have shown the data here only till [3] => stdClass Object
, but the original list is long.
Array
(
[0] => stdClass Object
(
[ID] => 100000173
[FirstName] => a
[LastName] => b
)
[1] => stdClass Object
(
[ID] => 100000174
[FirstName] => c
[LastName] => d
)
[2] => stdClass Object
(
[ID] => 100000175
[FirstName] => e
[LastName] => f
)
[3] => stdClass Object
(
[ID] => 100000176
[FirstName] => g
[LastName] => h
)
)
I received the above result from the following code..
$MBclients = $classService->GetClients(array());
if(intval($MBclients->GetClientsResult->ResultCount) > 0)
{
echo "<pre>";print_r($MBclients->GetClientsResult->Clients->Client);//die;
}
The code that i tried to fetch data is
$info = $MBclients->id;
echo $info;
But it didn't showed any result. can anyone tell how to fetch the result