How to print nested stdclass object array
I am trying to print values in this nested stdClass Object but I'm having trouble accessing them. How do I print the ID? stdClass Object ( [AddUserWithLimitResult] => stdClass Object ( [Header] => stdClass Object ( [Code] => UserAdded [Description] => User created ) [ID] => 2243272 [UserName] => gmail.com [FirstName] => sar [LastName] => Sea [Email] => gmail.com [SubDomain] => olo ) ) I tried this: $object->AddUserWithLimitResult->Header->Code->ID; If you tab out the output it becomes clear that ID is a property of AddUserWithLimitResult stdClass Object ( [AddUserWithLimitResult] => stdClass