Answer the question
In order to leave comments, you need to log in
How to get value from php array?
Simple
question, I just saw it but I can't find the page again
. ] => 0 [error] => [status] => SUCCESS [type] => IN [statusText] => Success [trmTxnId] => 1584979277627 [account] => +3543545345345345[sum] => Array ( [amount] => 48 [currency] => 643 ) [commission] => Array ( [amount] => 0 [currency] => 643 ) [total] => Array ( [amount] => 48 [currency] => 643 ) [provider] => Array ( [id] => 7 [shortName] => QIWI Wallet [longName] => QIWI Wallet [logoUrl] => [description] =>
Basic data from the first array is retrieved
$status = $results[' status'];
And here from the second array how to take? We need the number 48 in this case .. It is in [sum] => Array ( [amount]
visually so
Array1
( [txnId] => 18010171325
[personId] => 534545454543
[date] => 2020-03-23T19:01 :19+03:00
[errorCode] => 0
[error] =>
[status] => SUCCESS
[type] => IN
[statusText] => Success
[trmTxnId] => 1584979277627
[account] => +3543545345345345
[sum ] => Array
( [amount] => 48
[currency] => 643 )
[commission] => Array
( [amount] => 0
[currency] => 643 )
[total] => Array ( [amount] => 48 [currency] => 643 ) [provider] => Array etc..
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question