Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

retrieving error codes w/ Authorize.net


dogpaw

Recommended Posts

I have a site using osCommerce with Authorize.net as the module. I have the credit card transactions fail all of a sudden. All the testing mode it was fine. Once in live mode, I used my own credit card and made a real purchase from my client's site.

 

All of a sudden, yesterday, an online customer got an error message and the check out failed. It reported a specific numbered AuthNet error message telling me that the login ID passed to AuthNet was incorrect. That had not changed at all. I ceased development on the site as of my successful live purchase. My client (the merchant) had not logged into the OSC Admin at all.

 

I then made a purchase on the site and it failed. However, I did not get a numbered AuthNet error message. OSC just spit out the friendly message that there was an error and to try the purchase again.

 

I've called AuthNet support and all they tell me is that I need to error code number for them to do anything to help.

 

What I need to know is this: Is the default AuthNet module coded to retrieve the response code fields? I've looked at the documentation from AuthNet and the code in the module but it's out of my league.

 

Can someone please confirm whether the default module is coded to completely retrieve the error codes from AuthNet. If not, how do I modify the code in the module to do so?

 

Thank you so much in advance

Link to comment
Share on other sites

We are experiencing very similar issues with Authorize.net.

 

We have ruled out location, avs mismatch, and credit card type. There appears to be no rhyme or reason for the declines....furthermore....

 

We have some transactions that do get processed fine.

If the card get's declined, it gets authorized anyway. We called the bank with the customers to verify that money is available, proof that the authorizing works fine, further complicating the matter, if the customer submits the order again, same error, and the card gets authorized AGAIN, resulting in a double authorization on the account, but still no order.

 

We have also noticed in some cases where the order will be completed on the authorize.net side, but nothing on the oscommerce side.

 

Are you seeing this behavior as well?

Need Hosting? Just ask!

Link to comment
Share on other sites

Yes it's similar.

 

When we first hit the wall yesterday with a customer not being able to make purchase, we obtained a new transaction key from AuthNet and plugged that into the OSC Admin. Then this same customer was then able to complete her purchase but not confirmation email from OSC and nothing in the order list in the Admin.

 

Hopefully someone helps us here because I'm looking really bad in my client's eyes right now. Her site is basically useless right now.

Link to comment
Share on other sites

I have a site using osCommerce with Authorize.net as the module. I have the credit card transactions fail all of a sudden. All the testing mode it was fine. Once in live mode, I used my own credit card and made a real purchase from my client's site.

 

All of a sudden, yesterday, an online customer got an error message and the check out failed. It reported a specific numbered AuthNet error message telling me that the login ID passed to AuthNet was incorrect. That had not changed at all. I ceased development on the site as of my successful live purchase. My client (the merchant) had not logged into the OSC Admin at all.

 

I then made a purchase on the site and it failed. However, I did not get a numbered AuthNet error message. OSC just spit out the friendly message that there was an error and to try the purchase again.

 

I've called AuthNet support and all they tell me is that I need to error code number for them to do anything to help.

 

What I need to know is this: Is the default AuthNet module coded to retrieve the response code fields? I've looked at the documentation from AuthNet and the code in the module but it's out of my league.

 

Can someone please confirm whether the default module is coded to completely retrieve the error codes from AuthNet. If not, how do I modify the code in the module to do so?

 

Thank you so much in advance

 

 

the default module basically only interprets an approval or a decline. it does not interpret or do anything with any of the "reason codes" that authorize.net provides when the card is declined.

 

authorize.net does provide a list of the codes, I think its on their website someplace. I did write some code a long time ago that basically reads the reason code provided by authorize.net and displays on the screen to the customer why the transaction got declined. if you look at some of my previous posts you should be able to find it easily as I posted it again just recently.

 

good luck!

Link to comment
Share on other sites

Same for my client.  We think this started on July 5th, but cannot be exactly sure.

 

We called authorize.net today and they blamed it on oscommerce.

 

 

Yes, the last successful purchase was I believe in June. The OSC site had not change at all and one day it's not working??? They blamed it on us for plugging in the wrong user ID and/or transaction key. We did not change that.

Link to comment
Share on other sites

i would be for checking what may be going on with your server itself, i have many people using authorizenet and no problems

 

 

I wish it were that easy. I've a 3 phone conversations with AuthNet today and told them over and over that the site had not changed and that it just didn't work all of a sudden. I too have 2 other OSC sites hooked up to AuthNet and they are both working fine. I even made a purchase on one of those other 2 sites today and it worked fine.

 

I started suggesting that there may be something wrong on their end with AuthNet's servers and the woman with customer service told me she had other calls to take and then just hung up.

Link to comment
Share on other sites

what a suprise....she hung up. we find that they don't want to talk much about it either.

 

I have 10 customers running oscommerce, other sites work fine....same server....

so it isn't us.

 

Any other suggestions?

keep in mind that we really aren't looking for reason codes of declines, if something is declined on the card site (bad exp date, no money) that is fine....but to authorize the card, and not log it into oscommerce side is very odd...yet the next transaction could work fine.

 

Again no real rhyme or reason...

 

 

Dogpaw...Question...

are your authorizing and capturing when the order is submitted?

we only authorize....but I don't see how this could be an issue if it worked fine before and just now started having issues.

Need Hosting? Just ask!

Link to comment
Share on other sites

what a suprise....she hung up. we find that they don't want to talk much about it either.

 

I have 10 customers running oscommerce, other sites work fine....same server....

so it isn't us.

 

Any other suggestions?

keep in mind that we really aren't looking for reason codes of declines, if something is declined on the card site (bad exp date, no money) that is fine....but to authorize the card, and not log it into oscommerce side is very odd...yet the next transaction could work fine.

 

Again no real rhyme or reason...

Dogpaw...Question...

are your authorizing and capturing when the order is submitted?

we only authorize....but I don't see how this could be an issue if it worked fine before and just now started having issues.

 

I think we are just authorizing. I didn't know that you could have an option for that.

Link to comment
Share on other sites

you have to modify the code to just authorize, then the customer logs in to auth.net to capture....

seems like you aren't doing this as you would have had to change the code....

that rules out that option.

Need Hosting? Just ask!

Link to comment
Share on other sites

correct. I have not changed the code.

 

I did just now try and install the v1.7 module with curl fix but I got nowhere with that. It kept throwing a parse error message telling me there were problems with the code. But of course, I don't have the knowledge to fix it.

Link to comment
Share on other sites

Check the time on your server because if it is off by 3 seconds from Authorize.net's time they will not accept the transaction.

 

You should also edit your catalog/includes/modules/payment/authorizenet.php file to display the return code on an error in the pre_confirmation_check() function.

 

Once you know the error code you can look in the API documentation from Authorize.net to determine the problem and how to correct it.

"Great spirits have always found violent opposition from mediocre minds. The latter cannot understand it when a man does not thoughtlessly submit to hereditary prejudices but honestly and courageously uses his intelligence." - A. Einstein

Link to comment
Share on other sites

Check the time on your server because if it is off by 3 seconds from Authorize.net's time they will not accept the transaction.

 

You should also edit your catalog/includes/modules/payment/authorizenet.php file to display the return code on an error in the pre_confirmation_check() function.

 

Once you know the error code you can look in the API documentation from Authorize.net to determine the problem and how to correct it.

 

I guess I'll check the server time, but do I have to call up AuthNet to find out what their server time is?

 

Also, getting the error codes was the initial topic of this thread when I posted. Do you know how to edit the file to display the codes? That's what I was originally looking for.

 

thanks

Link to comment
Share on other sites

Approx. line 259 in the catalog/includes/modules/payment/authorizenet.php file should read:

      tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(MODULE_PAYMENT_AUTHORIZENET_TEXT_ERROR_MESSAGE), 'SSL', true, false));

 

change it to read:

      tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode($HTTP_POST_VARS['x_response_reason_code'] . '-' . $HTTP_POST_VARS['x_response_reason_text'] . ' ' . MODULE_PAYMENT_AUTHORIZENET_TEXT_ERROR_MESSAGE), 'SSL', true, false));

 

and the error code and description will be displayed at the top of the checkout_payment page upon the return from authorize.net.

"Great spirits have always found violent opposition from mediocre minds. The latter cannot understand it when a man does not thoughtlessly submit to hereditary prejudices but honestly and courageously uses his intelligence." - A. Einstein

Link to comment
Share on other sites

Approx. line 259 in the catalog/includes/modules/payment/authorizenet.php file should read:

 ? ? ?tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(MODULE_PAYMENT_AUTHORIZENET_TEXT_ERROR_MESSAGE), 'SSL', true, false));

 

change it to read:

 ? ? ?tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode($HTTP_POST_VARS['x_response_reason_code'] . '-' . $HTTP_POST_VARS['x_response_reason_text'] . ' ' . MODULE_PAYMENT_AUTHORIZENET_TEXT_ERROR_MESSAGE), 'SSL', true, false));

 

and the error code and description will be displayed at the top of the checkout_payment page upon the return from authorize.net.

 

Thank so very much for this code. I'll place it on my page but hopefully I won't have to see those errors again.

 

thanks again.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...