Zen Cart Logo
Forums / Built-in Shipping and Payment Modules / Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

Views: 6,691

Results 1 to 20 of 21
9 Jan 2011, 4:34 PM
#1
ilikemike avatar

ilikemike

New Zenner

Join Date:
Dec 2010
Posts:
31
Plugin Contributions:
0

Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

I am using Zen-Cart 1.3.8a (with announced fixes applied) plus a few add-ons, for downloadable products only (i.e. the delivery system is totally automated).

Every once in a while, I receive an order as "two orders". That is, the customer only ordered once, PayPal notifies me of a single payment, but Zen-Cart creates two orders, with successive order numbers.

This is very troubling because this problem does not occur consistently or with apparent circumstances and so it is very hard to troubleshoot or point at the source of the problem (PayPal? Zen-Cart? Web-Host? Hackers?)

Comparing the two orders, I found the following differences only (except for Invoice No. of course):

                 Invoice No. **1                    Invoice No. **2
                 ---------------                    ---------------
IP Address:      75.171.230.185 - 75.171.230.185    75.171.230.185 - 66.211.170.66
Address Country: US                                 
Trans. Type:     web_accept                         unique
Payment Date:    11/30/1999 00:00:00                01/08/2011 21:13:31                
Exchange Rate:   1.00                               0.00

Have you seen this problem before? Do you know what causes it? A possible fix?

9 Jan 2011, 5:01 PM
#2
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

Haven't seen it, and don't know about a cause, but I suspect a switch to Paypal Express would possibly fix it.

9 Jan 2011, 7:42 PM
#3
ilikemike avatar

ilikemike

New Zenner

Join Date:
Dec 2010
Posts:
31
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

stevesh:

Haven't seen it, and don't know about a cause, but I suspect a switch to Paypal Express would possibly fix it.
Hmmm... I prefer not to switch to PayPal Express as this implies monthly fees and with my very low sales volume I can't afford that for now.

In the meanwhile, I found a very similar problem description here. So it seems that it is a known problem, except that due to its nature it is being described differently by different people (that's why it was hard for me to find it).

DrByte suggests there to "try this fix". I am not afraid of modifying PHP files but then how do I verify that this is indeed the fix for the problem?

My hosting BTW is not Windows but Linux:

Server OS: Linux 2.6.34.6 (CentOS)
PHP Version: 5.2.15 (Zend: 2.2.0)
Database: MySQL 5.1.52
HTTP Server: Apache mod_fcgid/2.3.5 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635

Additional tips and advice are most welcome. I hope that this will help many others experiencing the same problem.

Thanks.

9 Jan 2011, 8:51 PM
#4
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

There are no monthly fees with Paypal Express. You're thinking of Paypal Payments Pro. Paypal Express is pretty much like Paypal Standard, only more secure and stable. There really isn't any reason to use Paypal Standard (IPN) any more.

9 Jan 2011, 9:14 PM
#5
ilikemike avatar

ilikemike

New Zenner

Join Date:
Dec 2010
Posts:
31
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

stevesh:

There are no monthly fees with Paypal Express. You're thinking of Paypal Payments Pro. Paypal Express is pretty much like Paypal Standard, only more secure and stable. There really isn't any reason to use Paypal Standard (IPN) any more.
Oh, I may have been sleeping under a rock. Thanks for correcting my misconception about this. Do you happen to know whether Paypal Express allows purchases by customers who don't have a PayPal account? ("IPN - Website Payments Standard" does allow that)

10 Jan 2011, 12:02 PM
#6
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

It didn't used to, but it does now.

11 Jan 2011, 2:03 AM
#7
ilikemike avatar

ilikemike

New Zenner

Join Date:
Dec 2010
Posts:
31
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

stevesh:

It didn't used to, but it does now.
Perfect. Thanks so much.

BTW, "I suspect a switch to Paypal Express would possibly fix it" doesn't really encourage me to switch to PayPal Express.... but I will definitely try PayPal Express now that it allows customers who don't have a PayPal account to purchase with their credit card. Also, the prospect of an increase in conversion rate sounds promising (with the downside of possible increase in buyer's remorse).

11 Jan 2011, 11:10 AM
#8
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

"Every once in a while, I receive an order as "two orders""

makes it difficult to offer more definitive advice, particularly with a problem I can't test a solution for. Switching to the much more stable Paypal Express seemed the most logical first thing to try.

11 Jan 2011, 7:34 PM
#9
ilikemike avatar

ilikemike

New Zenner

Join Date:
Dec 2010
Posts:
31
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

stevesh:

makes it difficult to offer more definitive advice, particularly with a problem I can't test a solution for.
I agree as that's exactly what I wrote in the 3rd paragraph in my original post.

stevesh:

Switching to the much more stable Paypal Express seemed the most logical first thing to try.
Is it more stable because it has been tested by more people?

Theoretically, this problem could occur in Paypal Express as well, so it seems to me that the best way to test a solution is to let it be used for a long enough time (greater than 6 months) by as many people as possible. If no such problem is reported back, then we know it doesn't exist there. Unfortunately, I don't know a non-statistical test for a statistical problem like this, but if someone has an idea, this would be great.

26 Jan 2011, 12:39 PM
#10
tech_e avatar

tech_e

Zen Follower

Join Date:
Jan 2007
Posts:
159
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

I just experienced the same problem with a double order and single payment with PayPal. I've been using Zen Cart and PayPal for three years and this is the first time I've seen this problem. It looks like a PayPal problem with a double confirmation that created two orders.

What does it take to switch to PayPal Express?

Do I have to change anything with my PayPal account?

26 Jan 2011, 9:40 PM
#11
ilikemike avatar

ilikemike

New Zenner

Join Date:
Dec 2010
Posts:
31
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

Tech-E:

What does it take to switch to PayPal Express?
In the Zen-Cart Admin console you just need to enable PayPal Express and enter the codes provided by PayPal. It's really simple, no coding required or add-on install. It took me less than 5 minutes.

Tech-E:

Do I have to change anything with my PayPal account?
There is nothing to change in your PayPal account -- if you already have a Business Verified account with PayPal. All you have to do is get the API Access codes from PayPal:

http://www.zen-cart.com/index.php?main_page=page&id=15

Hope this helps. :smile:

28 Jan 2011, 12:46 AM
#12
tech_e avatar

tech_e

Zen Follower

Join Date:
Jan 2007
Posts:
159
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

Thanks. :smile:

Are you guys absolutely sure that PayPal Express allows a customer to use a credit card without setting up a PayPal account? I have not been able to verify that on the PayPal site and when I submitted the question to PayPal, I got an ambiguous response that did not answer my question.

With Express Checkout, your customers don't have to re-enter information
already stored on their PayPal account. After approving use of PayPal,
your customers return to your site to complete and finalize their
purchase. This provides your customers a secure and convenient payment
flow.This looks like a canned response.

About 60% of my customers who use PayPal do not set up an account. I can't use Express if a customer needs to sign up for a PayPal account.

4 Feb 2011, 4:53 AM
#13
drbyte avatar

drbyte

Sensei

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

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

Tech-E:

Are you guys absolutely sure that PayPal Express allows a customer to use a credit card without setting up a PayPal account?
If you enable "pay without account" in your Paypal account's payment-receiving preferences, then yes.
ref: https://www.zen-cart.com/tutorials/index.php?article=28

29 Dec 2011, 1:46 PM
#14
ilikemike avatar

ilikemike

New Zenner

Join Date:
Dec 2010
Posts:
31
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

Tech-E:

What does it take to switch to PayPal Express?
Did you eventually switch to PayPal Express?

Did it solve the problem?

I actually tried switching to PayPal Express but that created a different problem with my download-only products, so I switched back until I find the time to do a total migration from 1.3.8a to 1.5.0, removing a few unused add-ons in the process.

As a result, I am still experiencing this problem every once in a while. I am not sure whether this is in core-ZenCart or one of the add-ons the induces this problem.

BTW, the following old thread looks like it is referring to the same problem, and indeed the product in my case appears in two different categories via linking. Perhaps that's a clue to the root cause of the problem? http://www.zen-cart.com/forum/showthread.php?t=68306

29 Dec 2011, 4:26 PM
#15
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

This just happened to us overnight.

Customer placed order. All appears fine.
PayPal generated a second order (7 seconds later) with no customer data. Order total $0.00. Payment method GV/DC. Looking at order details, the amount embedded was identical to the total of the customer placed order.

IP address was PayPal. host address was [email protected]

Using PayPal Express.
Zencart v1.3.9H

The only difference that I can see is that the customer chose a different currency than default. AUD vs USD.

29 Dec 2011, 4:28 PM
#16
drbyte avatar

drbyte

Sensei

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

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

Was it Express Checkout? or Direct-Payment (website payments pro)?

29 Dec 2011, 5:08 PM
#17
ilikemike avatar

ilikemike

New Zenner

Join Date:
Dec 2010
Posts:
31
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

RixStix:

Using PayPal Express.
Zencart v1.3.9H
I am happy that I didn't waste time upgrading to 1.3.9h* only to switch to PayPal Express and find out that it didn't really help.

My modest experience taught me that if no one can come with an explanation for the root cause of a problem (however rare & random it is), then it will show up again, even in a newer & more robust version.

In this post there is a hint about "a server lag problem". But how can we take it from here? Is there a way to simulate some condition that can consistently re-produce the problem, so that an accurate diagnosis can be made and a solid fix can be tested?

*To clarify, upgrading to 1.3.9h is highly recommended, but not only to fix this particular problem.

29 Dec 2011, 5:09 PM
#18
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

It was Express.

We use Auth.net instead of WPP for CC transactions.

29 Dec 2011, 7:31 PM
#19
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

FWIW

PP order id is identical for the 2 sequential zencart orders.

First created by the customer. 2nd created by PP.

29 Dec 2011, 7:37 PM
#20
drbyte avatar

drbyte

Sensei

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

Re: Double-Order, One Charge (a bug in the PayPal IPN - Website Payments Standard?)

A DRASTIC workaround would be to go into your PayPal account and turn OFF the Instant Payment Notifications checkbox, so that it doesn't tell your store about ANY changes to your transactions, nor notifications of new transactions. This means your store won't be alerted of any echeck clearing or refunds or releases of holds, etc. You would have to update the order status by hand in those cases after you receive the email from PayPal about the event. If you can live with those consequences then that would be a workable "fix" for you.