You are here

function _uc_authorizenet_avs in Ubercart 6.2

Same name and namespace in other branches
  1. 5 payment/uc_authorizenet/uc_authorizenet.module \_uc_authorizenet_avs()
  2. 7.3 payment/uc_authorizenet/uc_authorizenet.module \_uc_authorizenet_avs()
1 call to _uc_authorizenet_avs()
_uc_authorizenet_charge in payment/uc_authorizenet/uc_authorizenet.module
Handles authorizations and captures through AIM at Authorize.Net

File

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

Code

function _uc_authorizenet_avs($code) {
  $text = $code . ' - ';
  switch ($code) {
    case 'A':
      $text .= t('Address (Street) matches, ZIP does not');
      break;
    case 'B':
      $text .= t('Address information not provided for AVS check');
      break;
    case 'E':
      $text .= t('AVS error');
      break;
    case 'G':
      $text .= t('Non-U.S. Card Issuing Bank');
      break;
    case 'N':
      $text .= t('No Match on Address (Street) or ZIP');
      break;
    case 'P':
      $text .= t('AVS not applicable for this transaction');
      break;
    case 'R':
      $text .= t('Retry – System unavailable or timed out');
      break;
    case 'S':
      $text .= t('Service not supported by issuer');
      break;
    case 'U':
      $text .= t('Address information is unavailable');
      break;
    case 'W':
      $text .= t('Nine digit ZIP matches, Address (Street) does not');
      break;
    case 'X':
      $text .= t('Address (Street) and nine digit ZIP match');
      break;
    case 'Y':
      $text .= t('Address (Street) and five digit ZIP match');
      break;
    case 'Z':
      $text .= t('Five digit ZIP matches, Address (Street) does not');
      break;
  }
  return $text;
}