0

Hi I am totally confused about bellow array. I know this is stupid question from who been coding for over 3 year like me.

I got a respond from server I declared as variable $respond

$result = json_decode($respond, true);

var_dump($result);

// the var_dump result is:
// array(1) { ["Message"]=> string(19) "Merchant not found." }

I want to get that message string to be echo, but end up with error.

I have tried:

echo $result['Message'];
echo $result[0]['Message'];
echo $result['Message'][0];
json_decode($result['Message'], true) //but return NULL

0 Answers0