Как вытащить переменные из массива?
Array
(
[result] => Array
(
[@attributes] => Array
(
[name] => getPlayerInfo
[success] => 0
)
[returnset] => Array
(
[error] => Array
(
[@attributes] => Array
(
[value] => GameRequest does not exist with token=token
)
)
[errorCode] => Array
(
[@attributes] => Array
(
[value] => 2000
)
)
)
)
)
$array = [
'result' => [
'@attributes' => ['name' => 'getPlayerInfo', 'success' => 0],
'returnset' => [
'error' => [
'@attributes' => ['value' => 'GameRequest does not exist with token=token']
],
'errorCode' => [
'@attributes' => ['value' => 2000]
]
]
]
];
echo $array['result']['returnset']['errorCode']['@attributes']['value']; // 2000
Сборка персонального компьютера от Artline: умный выбор для современных пользователей