3

I am using PayPal payflow gateway (Hosted Pages - Layout B) - and I have it all set up and working perfectly on desktop browsers.

However, when testing it on a mobile browser, I get the following error:

Token is missing. Please return to the website from where you started your purchase and try again. 

Paypal Error

I am using SECURETOKEN also. Here is my general flow:

  • User fills out name / address / information
  • User clicks Continue to Payment
  • Application sends a post to pilot-payflowlink.paypal.com with CREATESECURETOKEN=Y and SECURETOKENID={36 character token application generates} along with the rest of the POST data that the user submitted.
  • I get a response with RESULT=0 and a SECURETOKEN value.
  • I then redirect the user to https://pilot-payflowlink.paypal.com with the SECURETOKEN and SECURETOKENID in the url.
  • If on desktop, the site works fine. They are taken to the credit card page
  • If on mobile, they get the error noted above.

I am at a sheer loss. The paypal documentation states that layouts A and B will automatically redirect to the mobile page - but instead I am presented with the error below. I have no idea why.

I cannot find anything about this issue anywhere. Help is appreciated!

Barry Chapman
  • 6,690
  • 3
  • 36
  • 64

2 Answers2

2

Adding MODE=TEST resolved the problem. For example:

https://pilot-payflowlink.paypal.com/?SECURETOKENID=PFNSTI16NNN&SECURETOKEN=9avpLNBIxBEGXNLVPgVbXkQUN&MODE=TEST
Bill Bunting
  • 521
  • 6
  • 28
  • PP docs says MODE param is deprecated, they make me sick! Thank you, you saved my mind from explosion. – Serge P Sep 12 '17 at 17:20
  • This did fix my issue at the time, however - like @SergiiP said, it is now deprecated. You will use the pilot gateways and set the parameter in your post data if you wish to enable the test mode! Sorry for the late acceptance, but its the thought that counts, right? – Barry Chapman Feb 07 '18 at 01:56
  • Thank you!! So is this a problem that only affects the test environment, or do we need to add a `MODE=` in live too? – Hutch Feb 28 '18 at 21:03
  • MODE=TEST was only needed for testing. – Bill Bunting Mar 01 '18 at 01:23
0

I too had come across the same issue, it got resolved after i added TEMPLATE=templateA to the posted data.

Sangamesh
  • 11
  • 3