0

我收到了回复 $oResponse:

object(stdClass)[5]
  public 'transaction' =>
    object(stdClass)[6]
      public 'sId' => string '55PT1U-ELU4Z8-7RDTJY' (length=20)
      public 'sDate' => string '2012-12-13 17:32:45' (length=19)
      public 'fAmount' => int -10
      public 'sCurrency' => string 'USD' (length=3)
      public 'fFee' => int 0
      public 'sType' => string '(api) Sent to' (length=13)
      public 'iTypeId' => string '12' (length=2)
      public 'sEmail' => string 'receiver@test.com' (length=19)
      public 'sDetails' => string 'Api send test' (length=12)
      public 'sStatus' => string 'Completed' (length=9)
  public 'status' => string 'ok' (length=2)

然后尝试解析一个状态:

echo $oResponse->{5}->status;

但它不起作用:(

4

1 回答 1

1

尝试改变这一点

echo $oResponse->status;
于 2013-07-12T00:00:07.053 回答