I am calling api using wp_remote_post() method.I am getting below response from api
Array
(
[headers] => Array
(
[cache-control] => no-cache
[pragma] => no-cache
[content-length] => 100
[content-type] => application/json
[content-encoding] => deflate
[expires] => -1
[server] => Microsoft-IIS/8.5
[x-aspnet-version] => 4.0.30319
[date] => Fri, 27 May 2016 12:47:01 GMT
[connection] => close
)
[body] => {"ResponseStatus":false,"ResponseData":null,"ErrorData":{"ErrorCode":"E0002","Error":"Email already registered.","ErrorDetail":"Email already registered."}}
[response] => Array
(
[code] => 200
[message] => OK
)
[cookies] => Array
(
)
[filename] =>
)
I want to access all properties of above object
I am trying to access using below code
$res->ResponseStatus;
but it print nothing.
1 comment