Can anyone give me example for structs data type in php ? How come there is something like structs in php all of a sudden ?
It seems that the struct datatype is commonly used in SOAP:
var_dump($client->__getTypes());
array(52) {
[0] =>
string(43) "struct Bank {\n string Code;\n string Name;\n}"
}
This is not a native PHP datatype!
It seems that the properties of the struct type referred to in SOAP can be accessed as a simple PHP stdClass object:
$some_struct = $client->SomeMethod();
echo 'Name: ' . $some_struct->Name;