Onstar Posted August 18, 2005 Posted August 18, 2005 Hello everybody, This problem here has plagued me for almost a month and half now. I get an error message "There has been an error processing your credit card. please try again." during checkout when I click on "confirm order". I found the following code which is a part of the payment pro code function before_process() { global $HTTP_POST_VARS, $order; $order->info['cc_type'] = $HTTP_POST_VARS['paypal_cc_type']; $order->info['cc_number'] = substr($HTTP_POST_VARS['paypal_cc_number'], 0, 4) . str_repeat('X', (strlen($HTTP_POST_VARS['paypal_cc_number']) - 8)) . substr($HTTP_POST_VARS['paypal_cc_number'], -4); $order->info['cc_owner'] = $HTTP_POST_VARS['paypal_cc_firstname']. ' ' .$HTTP_POST_VARS['paypal_cc_lastname']; $order->info['cc_expires'] = $HTTP_POST_VARS['paypal_cc_expires_year']; require_once ('Services/PayPal.php'); require_once ('Services/PayPal/Profile/Handler/Array.php'); require_once ('Services/PayPal/Profile/API.php'); $certfile = DIR_FS_CATALOG. MODULE_PAYMENT_PAYPAL_DP_CERT_FILE; $certpass = ''; $apiusername = MODULE_PAYMENT_PAYPAL_DP_USERNAME; $apipassword = MODULE_PAYMENT_PAYPAL_DP_PASSWORD; $subject = ''; $environment = MODULE_PAYMENT_PAYPAL_DP_GATEWAY_SERVER; $handler =& ProfileHandler_Array::getInstance(array( 'username' => $apiusername, 'certificateFile' => $certfile, 'subject' => $subject, 'environment' => $environment)); $profile =& APIProfile::getInstance($apiusername, $handler); $profile->setAPIPassword($apipassword); $caller =& Services_PayPal::getCallerServices($profile); if(Services_PayPal::isError($caller)) { // var_dump($response); tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(MODULE_PAYMENT_PAYPAL_DP_TEXT_PROCESS_ERROR), 'SSL', true, false)); } //MODULE_PAYMENT_PAYPAL_DP_TEXT_PROCESS_ERROR = "There has been an error processing your credit card. please try again." So, according to the above code, it is telling me something about my 'apiusername', 'apipassword', 'certificate'. I have looked at those and used the exact password and apiusername. I don't know what else I can think of that's causing the error. Please help Thanks Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.