You are here

function _uc_authorizenet_cim_parse_response in Ubercart 6.2

Same name and namespace in other branches
  1. 8.4 payment/uc_authorizenet/uc_authorizenet.module \_uc_authorizenet_cim_parse_response()
  2. 5 payment/uc_authorizenet/uc_authorizenet.module \_uc_authorizenet_cim_parse_response()
  3. 7.3 payment/uc_authorizenet/uc_authorizenet.module \_uc_authorizenet_cim_parse_response()

Parse an Authorize.Net XML CIM API response.

4 calls to _uc_authorizenet_cim_parse_response()
_uc_authorizenet_cim_payment_profile_get in payment/uc_authorizenet/uc_authorizenet.module
Get a CIM payment profile stored at auth.net.
_uc_authorizenet_cim_profile_charge in payment/uc_authorizenet/uc_authorizenet.module
Use a reference to charge to a CIM profile.
_uc_authorizenet_cim_profile_create in payment/uc_authorizenet/uc_authorizenet.module
Create a CIM profile using an order's data.
_uc_authorizenet_cim_profile_get in payment/uc_authorizenet/uc_authorizenet.module
Get a CIM profile stored at Authorize.Net.

File

payment/uc_authorizenet/uc_authorizenet.module, line 1165
Process payments using Authorize.net. Supports AIM and ARB.

Code

function _uc_authorizenet_cim_parse_response($content) {

  // Find the elements in the XML and build the return array.
  $data = array(
    'refId' => _uc_authorizenet_substr_between($content, 'refId'),
    'resultCode' => _uc_authorizenet_substr_between($content, 'resultCode'),
    'code' => _uc_authorizenet_substr_between($content, 'code'),
    'text' => _uc_authorizenet_substr_between($content, 'text'),
    'customerProfileId' => _uc_authorizenet_substr_between($content, 'customerProfileId'),
    'directResponse' => _uc_authorizenet_substr_between($content, 'directResponse'),
    'customerPaymentProfileId' => _uc_authorizenet_substr_between($content, 'customerPaymentProfileId'),
    'customerAddressId' => _uc_authorizenet_substr_between($content, 'customerAddressId'),
  );
  return $data;
}