0

I'm new with json and web service. After using insert command, I do print_r($result) and got this data:

Array ( [error_code] => 0 [error_desc] => [result] => Array ( [error_code] => 999 [error_desc] => Format input 'date' is wrong ) )

I want to print the error_desc only which is show Format input 'date' is wrong.

I try to parsing it with PHP but I only got empty result. Here is my code:

if (is_array($result)) {
    if ($result['error_code'] =='999') {
      echo $result['error_desc'];
    }
  }

Please help. Thanks.

Alive to die - Anant
  • 70,531
  • 10
  • 51
  • 98
vanhook
  • 27
  • 4

1 Answers1

0

I already got the answer. I just know after print the error_code. Thanks.

vanhook
  • 27
  • 4