Zen Cart Logo
Forums / Built-in Shipping and Payment Modules / duplicate orders in authorize AIM

duplicate orders in authorize AIM

Locked

Views: 5,769

Results 1 to 19 of 19
This thread is locked. New replies are disabled.
3 Oct 2007, 3:02 PM
#1
andes avatar

andes

New Zenner

Join Date:
Jun 2007
Posts:
27
Plugin Contributions:
0

duplicate orders in authorize AIM

Today i found that I have a dupliecate order from the same client in authorize.net 4 times ( two with id and other 2 with other xxxx514 and xxx515 ) but no order in zen, the orders are separated +- 20 minutes between them, and another order with the same id but from another customer appear in authorize.net and zen . finally when i enter the client account the product is still in his basket, any idea?

Thanks

3 Oct 2007, 8:34 PM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: duplicate orders in authorize AIM

You could try installing the attached module update which prevents duplicate order numbers from being sent to Authorize.net.

You'll need to write down all your current AIM module settings, then Remove the module. Then upload the new files. Then re-Install in the Admin, and re-enter your module settings including transaction key.

There's a new field for MD5 Hash. If you want to use it, you'll need to set an MD5 hash 'phrase' in your Authorize.net merchant account settings. Then enter that same phrase in your Zen Cart AIM module settings. It's just an extra layer of security. If you don't use it, just leave it blank on both ends.

The following code is built-in to v1.3.8, along with additional improvements.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

4 Oct 2007, 2:59 PM
#3
andes avatar

andes

New Zenner

Join Date:
Jun 2007
Posts:
27
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

thanks for the reply, i'll give it a try

7 Dec 2007, 12:45 AM
#4
afx114 avatar

afx114

Zen Follower

Join Date:
Aug 2005
Posts:
144
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

Dr. Byte,

Is this updated Authorize.net AIM module compatible with 1.2.x?

7 Dec 2007, 5:52 AM
#5
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: duplicate orders in authorize AIM

afx114:

Dr. Byte,

Is this updated Authorize.net AIM module compatible with 1.2.x?

No. There are dependencies in it which require v1.3.x in order to work.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

25 Feb 2008, 9:58 PM
#6
jrlooney avatar

jrlooney

New Zenner

Join Date:
Feb 2008
Posts:
16
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

in case someone comes across this thread. i had the problem and just changed to use the Authorize.net AIM module instead of SIM and it works fine in v1.3.8

8 Apr 2008, 5:30 AM
#7
pensive612 avatar

pensive612

Zen Follower

Join Date:
May 2006
Posts:
313
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

Hi,

I'm using 1.38 with authorize AIM. and i'm getting duplicate orders with unique ID's, but same checkout time.

Does the Sept AIM update apply to the 1.38 module as well?

Thanks in advance.

  • pensive612
8 Apr 2008, 1:34 PM
#8
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: duplicate orders in authorize AIM

pensive612:

Hi,

I'm using 1.38 with authorize AIM. and i'm getting duplicate orders with unique ID's, but same checkout time.

Does the Sept AIM update apply to the 1.38 module as well?

Thanks in advance.

The posted AIM patch is already built-in to v1.3.8.

Is your site an upgrade from a prior version?
Are you sure that the authorizenet_aim.php payment module file got updated to the 1.3.8 version?

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

8 Apr 2008, 6:11 PM
#9
pensive612 avatar

pensive612

Zen Follower

Join Date:
May 2006
Posts:
313
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

Thanks for you response Dr. Byte.

I had a feeling it was already updated. It is a fresh 1.38 install.

I followed anothers advice and switched the session cache to file. So far so good!

I will post if that turns out to not work...

Thanks again for your time.

  • pensive612
9 Apr 2008, 6:54 AM
#10
pensive612 avatar

pensive612

Zen Follower

Join Date:
May 2006
Posts:
313
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

Okay. So I'm extra baffled.

I switched the cache method to file in my configure.php file.

I ran fix_cache_key.php to double check my settings. (files are being written there)

Works great on Firefox. But on IE. The 'confirm purchase' link takes them to an empty shopping cart!

i've tested it a 100 times. and switching back to db sessions is the only thing that affects it.

Dr. Byte, any ideas?

Thanks again, so much.

  • pensive612
9 Apr 2008, 9:12 AM
#11
pensive612 avatar

pensive612

Zen Follower

Join Date:
May 2006
Posts:
313
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

I think I found the answer.

In Configuration>Sessions

I needed to have Recreate Session to false.

Apparently for me, IE7 is getting errors with it set to true.

Seems to work so far.

Hope that helps someone in the future.

  • pensive612
9 Apr 2008, 1:58 PM
#12
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: duplicate orders in authorize AIM

pensive612:

I switched the cache method to file in my configure.php file.

I ran fix_cache_key.php to double check my settings. (files are being written there)

Works great on Firefox. But on IE. The 'confirm purchase' link takes them to an empty shopping cart!

i've tested it a 100 times. and switching back to db sessions is the only thing that affects it.

pensive612:

I think I found the answer.

In Configuration>Sessions

I needed to have Recreate Session to false.

Apparently for me, IE7 is getting errors with it set to true.Those will be issues specific to your server.
Indeed, disabling Recreate Session is dangerous, in that it allows visitors to your site to potentially hijack other customers' shopping sessions. However, some hosting companies configure their servers in such a way that turning off Recreate Session is the only way to make things operate at all. IMO they're foolish to do so, but as long as people keep paying them money to host there, the problems will perpetuate.

But, now we are digressing from the topic at hand.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

14 Apr 2008, 7:03 PM
#13
pensive612 avatar

pensive612

Zen Follower

Join Date:
May 2006
Posts:
313
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

Hi Dr. Byte.

You are definitely right about not Recreating Sessions, and thanks for the advice. I've since switched back to db with Recreate Sessions enabled.

This was thanks to a great post from paulm about a 'submit once' fix he made. and so far, it seems to have fixed the problem.

Have you by any chance seen his fix? I wonder if it might be incorporated into the code later on?

Thanks again for your time.

  • pensive612
13 Oct 2010, 10:02 PM
#14
cleverpork avatar

cleverpork

Zen Follower

Join Date:
Apr 2007
Location:
Washington
Posts:
115
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

Howdy, all.

I'll just jump right into my question. Non-techy type here, but I've been doing my due-dilligence trying to read before posting.

Here's the scoop on why I'm jumping in.

I'm running version 1.3.7, and using authorize.net. I'm getting this infamous 1064 error, it seems when an apostrophe is used in the product title and/or when an apostrophe is in customers name or address.

I was unable to find my 'exact' error on the boards and since I'm a little trepid to just start attacking the issue without at least asking, thought I'd share the error and get some input/advice.

I created a test customer and forced the error by adding an apostrophe in the customer's name.

Here's what that yielded;

1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 's Cunningham [x_address] => 1234 Grandstand's Blvd. [x_city] => Nashvill' at line 1
in:
[insert into authorizenet (id, customer_id,order_id, response_code, response_text, authorization_type, transaction_id, sent, received, time, session_id) values


The error went on longer, but I wasn't certain if that info was secure info for public showing.

Any guidance is greatly appreciated. Thanks a ton!

Cris

13 Oct 2010, 10:41 PM
#15
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: duplicate orders in authorize AIM

Upgrading to v1.3.9 will solve that problem.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

15 Oct 2010, 2:04 PM
#16
cleverpork avatar

cleverpork

Zen Follower

Join Date:
Apr 2007
Location:
Washington
Posts:
115
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

DrByte:

Upgrading to v1.3.9 will solve that problem.

Thanks for your response, DrByte! I really appreciate it. While this is the the best solution, with fall/Christmas being our biggest time of the year, I'm at a major crunch for time until early 2011. I did look into what it takes to upgrade and I fear that it may be a larger job than I have time (I have a few addons and have had a nice cron job built for the site. Don't want to mess those up during the holiday season).

In the meantime, is there a simpler solution to mend the apostrophe / 1064 issue (the one specific to my post above)? Then early 2011 I can begin the upgrade process.

Again, thanks for your time. I appreciate it.

Cris

Cris

15 Oct 2010, 3:37 PM
#17
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: duplicate orders in authorize AIM

Did you try the patch posted above?

I haven't looked at 1.3.7 in so long I forget what it looks like :blush:

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

15 Oct 2010, 9:33 PM
#18
cleverpork avatar

cleverpork

Zen Follower

Join Date:
Apr 2007
Location:
Washington
Posts:
115
Plugin Contributions:
0

Re: duplicate orders in authorize AIM

DrByte:

Did you try the patch posted above?

I haven't looked at 1.3.7 in so long I forget what it looks like :blush:

Ha! Sorry, I'm outdated here. I really do need to upgrade and have been aware for some time.

I was a bit confused if the patch above was suitable to my issue so I didn't attempt it yet. It seems like it might be appropriate, but since there was some variation in the error messages compared to mine, I was reluctant to apply this patch.

Do you think, by looking at my above posting of the error that this is the patch for me?

Cris

19 Oct 2010, 4:21 AM
#19
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: duplicate orders in authorize AIM

I'd start with the patch, after making a backup of the file you've got currently.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.