function _uc_paypal_build_error_messages in Ubercart 7.3
Same name and namespace in other branches
- 6.2 payment/uc_paypal/uc_paypal.module \_uc_paypal_build_error_messages()
Builds error message(s) from PayPal failure responses.
1 call to _uc_paypal_build_error_messages()
- uc_paypal_wpp_charge in payment/
uc_paypal/ uc_paypal.module - Processes a credit card payment through Website Payments Pro.
File
- payment/
uc_paypal/ uc_paypal.module, line 373 - Integrates various PayPal payment services and Instant Payment Notifications (IPN) with Ubercart!
Code
function _uc_paypal_build_error_messages($nvp_response) {
$code = 0;
$message = '';
while (array_key_exists('L_SEVERITYCODE' . $code, $nvp_response)) {
$message .= '<br /><b>' . check_plain($nvp_response['L_SEVERITYCODE' . $code]) . ':</b> ' . check_plain($nvp_response['L_ERRORCODE' . $code]) . ': ' . check_plain($nvp_response['L_LONGMESSAGE' . $code]);
$code++;
}
return $message;
}