Jump to content

User logged out after redirection


Recommended Posts

Hello

We are trying to build a payment module that give the possibillity to pay by a local gateway.

The module work as follow:

1- the customer select the module payment option and press the order button.

2- Prestashop website initialise a payment and set the success url and the error URL using CURL.

3-Prestashop website redirect the customer (Tools::redirect ) to the pyment gateway website.

4- After paying, the gateway redirect the customer to Prestashop (success URL or error URL.)

Everything work perfect, except that when the gateway redirect the customer to Prestashop, the user appears to be logged out and must re login.

Is there any restriction in using Tools::redirect to another website?

 

thanks

Link to comment
Share on other sites

  • 5 months later...
  • 4 months later...
  • 10 months later...

Hello, (sorry for the English grammar).
I have had this excact issue for quite some time, which also resulted in me digging down in the payment module (QuickPay/PensoPay) itself (came from third party) and besides that when i made a work-around the data was not trackable in google analytics.
After many many hours looking in basically every prestashop file dealing with payments and order-confirmations and no answers on google besides topics like this with others dealing with the same problem, i was wondering if it could have something to do with the cookies! AND YES IT DOES! 😝
(Sorry for the Danish backoffice... I went to advanced parameters->Administration->SameSite cookies and changed it from Strict to "none" which resolved the issue right away!

Let me know if this works for some of you as well!

cookies ffs.JPG

  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...