Support

Home Forums Event Espresso Premium Duplicated payment received mails

Duplicated payment received mails

Posted: September 28, 2018 at 8:55 am


Biznetaucoeur

September 28, 2018 at 8:55 am

Hi,

I’ve a problem on EE4. Clients are receiving two payment received emails each payment done. It is pretty disappointing because it is a bit confusing for them and doesn’t look professional.

Important informations of my installation :
Version WordPress: 4.9.8
Version PHP: 7.0.32
Version MySQL 5.5.5
Version Event Espresso : 4.9.63.p

I’ve already checked this topic :
https://eventespresso.com/topic/duplicate-payment-received-emails/

But answers provided don’t work.

Can you tell if you have tips or something i must check to fix that problem?

Thanks,


Josh

  • Support Staff

September 28, 2018 at 9:05 am

Hi,

Can you check the Event Espresso > Messages > Messages Activity page and look for duplicate listings of the same Payment Received emails? That’s the first thing to check. Another thing to check would be if there are other email types going out at the same time (like a Registration Approved email and/or a Ticket Notice email). Since these can be configured to have very similar content as the Payment Received email they may be perceived as two identical emails.


Biznetaucoeur

October 1, 2018 at 1:18 am

Hi Josh,

Thank you very much for your answer.
In my WordPress Admin Panel, Event Espresso > Messages, I have duplicate listings of the same Payment Received emails. Each duplicata is going out at the exactly same time, and is from the same email type “Payment Received”.
The thing which is strange is that sometimes (still very rarely), there’s only one email being sent to the customer (no duplicata).

Thanks for helping me with that problem,
Have a great day,


Biznetaucoeur

October 1, 2018 at 1:20 am

PS: I would like to specify I’ve already parametered in Messages > Settings, Sending messages on the same request, if that could help.


Tony

  • Support Staff

October 1, 2018 at 4:20 am

Hi there,

Have you edited the Payment Received message template at all? It sounds like you may have activated the ‘Event Admin’ context for the payment received template and have set that context to go to the registrant, as the registrant also has its own content on that template, they receive both.

If you go to Event Espresso -> Messages -> Default message templates (assuming you are using the default template?)

Then in the list look for the payment received message template, does it show both the ‘Event Admin’ and ‘Primary’ registrant text in blue or is the ‘Event Admin’ text grey? Like this – http://take.ms/7Nh1f

Click on the ‘Event admin’ text to view its context, what is displayed in the ‘To’ field there?


Biznetaucoeur

October 1, 2018 at 5:22 am

Hi Tony,
Thanks for your answer,
-In the default message templates, when i look for the payment received template, it shows ‘Event Admin’ text in grey, and ‘Primary Registrant’ text in blue. Actually, it is exactly the same thing as your screenshot.

-When I click on ‘Event Admin’ to view its context, the ‘To’ field is empty.

Thanks for your help


Biznetaucoeur

October 1, 2018 at 5:59 am

I’m not sure but the problem could actually come from further than that. In parallel of duplicate payment received emails, I’m having issues with registration status :

Some of the transactions have a status of ‘Completed’ while the registration status stays on ‘Pending Payment’. I’ve checked further in Payment Methods > Logs and there, i can see there is actually 4 logs recorded for each transaction :
-1 with IPN data received (content of the log is those fields :
uts, step, action, selected_method_of_payment, spco_txn, DATA, post_id, post_name, registration-checkout, post_type, is_espresso_page)
-1 with Post Payment Transaction Details (content of the log is those fields :
message, transaction, finalized, IPN, deliver_notifications)
-1 duplicata of the first log with IPN data received
-1 duplicata of the second log with Post Payment Transaction Details


Biznetaucoeur

October 1, 2018 at 6:01 am

I’m thinking there is something duplicating things (more steps than only the payment received emailing) in the registration process


Josh

  • Support Staff

October 1, 2018 at 9:40 am

May I ask what’s the Payment Method selected for those transactions? e.g. PayPal, Stripe, or Authorize.net?


Biznetaucoeur

October 2, 2018 at 1:24 am

Hi Josh,
For sure,
Since ATOS payment method wasn’t available for EE4, my predecessor (as a web developper in a web agency), created his own payment method for ATOS. Since then, we’re using that payment mehod.


Biznetaucoeur

October 3, 2018 at 1:50 am

Hi Josh,
I investigated and i’ve come to realize that the problems of duplicated mails and Registration status staying to ‘Pending Payment’ while the transaction is completed might come from the payment platform and transmitted data between the platform and my site.

In fact, my site doesn’t have a SSL certificate installed at the moment, that said, when my customers pay on the bank/payment platform, according to their browser, they often get a browser pop-up saying that data is transmitted as plain data (not encrypted) between bank/payment platform and my site.

If they continue by accepting this fact, the transaction gets completed, the registration status becomes ‘Approuved payment’ and everything works as expected in EE, except the fact that they still receive 2 duplicate mails of ‘Payment Received’, and another one about their confirmed registration (not duplicated).

If they doesn’t accept the fact that data is transmitted as plain data, the payment platform doesn’t redirect on my site (absolutely normal behavior i guess), but still, some data is transmitted since Event Espresso updates the transaction status to be completed. In this case scenario, the registration status doesn’t get updated and stays on ‘Pending Payment’ (I guess it’s normal, because some response data from the bank platform hasn’t been transmitted as well). In this case, they still have a ‘Payment Received’ email (not duplicated), but they don’t receive the confirmed registration email. (I guess it’s normal as well since the registration is not ‘Payment Approuved’).

So that said, i can clearly there is something like 2 data response events :
-When the payment is done, EE gets a first response about completed payment even if the user doesn’t want the uncrypted data to be transmitted, and updates transaction the be completed, and fires the ‘Payment received’ email.
-Then, if the users accept the fact that data is transmitted as plain data, EE gets somtehing like a second response, that fires another ‘Payment Received’ email to the customer, and updates the Registration Status as ‘Approuved Payment’.

I hope those elements can help you to solve the problem i’m encountering.

I have some questions as well i want to ask you :
-I’m definitely installing a SSL certificate on this site next days. Will it solve the ‘data transmitted as plain data’ response from the payment platform? I guess that if it does, everything might goes right and EE might updates Registration Status as ‘Approuved Payment’ each time.
-Will it fix the problem of duplicated ‘payment received’ emails?

Apologies for the long post, but i hope that this can help.

Thanks a lot for your patience and your support.

Biznetaucoeur


Tony

  • Support Staff

October 3, 2018 at 5:37 am

Hi there,

The problem is not EE, it’s the payment method you are using as all of the updates are done through the payment method.

-When the payment is done, EE gets a first response about completed payment even if the user doesn’t want the uncrypted data to be transmitted, and updates transaction the be completed, and fires the ‘Payment received’ email.

Means ATOS is likely sending an ‘IPN’ request (a separate request that indicates a payment has been made, this request is sent directly from ATOS/the payment merchant, to you site) which contains details of the payment, EE receives the IPN, identifies the payment and payment method it is for and then simply calls the payment method to do whatever it is set up to do with the IPN data.

(Note EE itself isn’t doing anything here other than recieveing the request to the /transactions/ page, logging the data and then calling the payment method)

-Then, if the users accept the fact that data is transmitted as plain data, EE gets somtehing like a second response, that fires another ‘Payment Received’ email to the customer, and updates the Registration Status as ‘Approuved Payment’.

Means that ATOS likely sends an IPN request AND when the user clicks accept to redirect the user back, they POST the user back to the transactions page, which again EE logs the details and calls the payment method to do it’s thing…

(Again note that EE core is not doing very much here, it’s all down to the payment method, the whole idea being that payment methods can do VERY different things depending on how the merchant wants it to work)

-I’m definitely installing a SSL certificate on this site next days. Will it solve the ‘data transmitted as plain data’ response from the payment platform?

It should fix the notice but to be clear, the notice is not from EE, it’s from the merchant and is showing because they are about to redirect the user back to the site and the payment method passed an ‘insecure’ URL for that redirect.

We didn’t write the payment method so can’t provide support for it nor answer with 100% certainty, but as mentioned, it should fix that notice.

Note that to be PCI Compliant you must have an SSL certificate installed on your site, event if you are just redirecting the user to an offsite payment merchant.

I guess that if it does, everything might goes right and EE might updates Registration Status as ‘Approuved Payment’ each time.

As mentioned, this isn’t an issue with EE itself, it’s the payment method, so I have no idea if that will fix the problem.

-Will it fix the problem of duplicated ‘payment received’ emails?

This is unlikely as it appears the payment method has not been coded to handle IPN’s correctly.

Have you tested another offsite payment method to confirm if you get the same issue with that?

Note that as we didn’t write the ATOS payment method you are using, we can’t provide support for it and you’ll likely need to contact the developer who created it to investigate further.


Biznetaucoeur

October 5, 2018 at 1:26 am

Hi Tony,

Thank you very much for your very precise answer. I can now understand where the problem really is, so i’ll be investigating further if the SSL certificate isn’t sufficient to fix problems i’m encountering.

Have a great day


Tony

  • Support Staff

October 5, 2018 at 4:53 am

You’re most welcome.

I’d recommend testing another payment method to confirm the above is the case as without seeing the code it is just an educated guess knowing how EE works with payment methods.

I don’t know for a certainty how the integration with ATOS works but we’ve seen the same issue from other custom payment methods when not set up to handle IPN’s and POST backs correctly.

The support post ‘Duplicated payment received mails’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso