Paypal Express – Live checkout goes to PP sandbox!
-
Hi. I am in the process of setting up PP Express on my live site having done successful testing in development. It al worked against the PP sandbox, but when I turn off sandbox and set up live credentials, checkout still takes me to the sandbox PP – https://www.sandbox.paypal.com
Just before switching to Live, I upgraded the plugin to v1.5.0. I am using WooCommerce 3.5.1.
Any pointers would be much appreciated.
-
Hi @colinfroggatt,
I believe this is some sort of cache issue, Are you using any cache or CDN services? Can you disabled them temporarily, clear caches then give it another shot and see if that makes any difference?
@gingeralfie , could you provide some more information about that? Also, per the WP forum rules, You should create a separate support request and provide all the information relevant to issue.
Thank you!
Hi Oliver. sorry for the late rreply but got pulled off to something else.
I tried again today and I am seeing the same issue. I purged Cloudflare CDN and turned on it’s dev mode and also purged the local WP cache but still seeing the same problem – going to
https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_express-checkout&useraction=continue&token=EC-5xxxxxxxxxxx
rather than live PP site.Any ideas?
cheers, Colin
Hi. I just setup live PP credentials on our test system and this works as expected! Is there any debugging hints you can give me to be able to track what on our live system is causing the issue.
The dev system does not go thru Cloudflare, but that should not be an issue as I cleaned it out on live as mentioned above.
Hi, I have captured the http req/resp from the Woo Checkout button. We can see that Woo/PP Express is redirecting the customer (via 302) to PP Sandbox. Not sure how caching would get in the way of this. Help!
cheers, Colin
REQ: click checkout button
————————————POST: https://www.example.com/?wc-ajax=checkout REQ headers: Host: www.example.com User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:63.0) Gecko/20100101 Firefox/63.0 Accept: application/json, text/javascript, */*; q=0.01 Accept-Language: en-GB,en;q=0.5 Accept-Encoding: gzip, deflate, br Referer: https://www.example.com/checkout/ Content-Type: application/x-www-form-urlencoded; charset=UTF-8 X-Requested-With: XMLHttpRequest Content-Length: 659 Connection: keep-alive Cookie: _ga=GA1.2.677610765.1531824410; gadwp_wg_default_metric=sessions; gadwp_wg_default_dimension=30daysAgo; gadwp_wg_default_swmetric=sessions; session_locale=en; __stripe_mid=ca65fe62-8cea-45c4-8bd0-a33f7aa2fba1; __cfduid=d89ed227xxxxxb58dd8e3badd9e4392511535996149; wp-settings-159=exxxxx; wp-settings-time-159=1541368336; intercom-id-r7xxgx=753-d462-4a76-baff-2004c9; wp_woocommerce_session_be481d1de1d72=159%7C%7C1541858001%7C%7C1541854401%7C%7C7e131f5f824307ad9; PHPSESSID=vihmnjo7; woocommerce_items_in_cart=1; woocommerce_cart_hash=295dc81963779283; wpfront-notification-bar-landingpage=1; wordpress_test_cookie=WP+Cookie+check; wordpress_logged_in_be481d18a442=Coxxxx%7C15416WC6H2Xnc21m%7Cdae61c1cafa91; pmpro_visit=1; _gid=GA1.2.5027693; __stripe_sid=952-950c-ca24b09d6f46 Pragma: no-cache Cache-Control: no-cache TE: Trailers STATUS: 200 RESP: result success redirect (302) https://www.example.com/wc-api/WC_Gateway_PayPal_Express_AngellEYE/?pp_action=set_express_checkout&utm_nooverride=1 {"result":"success","redirect":"https:\/\/www.example.com\/wc-api\/WC_Gateway_PayPal_Express_AngellEYE\/?pp_action=set_express_checkout&utm_nooverride=1"} 302 REQ: ----------- https://www.example.com/wc-api/WC_Gateway_PayPal_Express_AngellEYE/?pp_action=set_express_checkout&utm_nooverride=1 Headers: Host: www.example.com User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:63.0) Gecko/20100101 Firefox/63.0 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language: en-GB,en;q=0.5 Accept-Encoding: gzip, deflate, br Referer: https://www.example.com/checkout/ Connection: keep-alive Cookie: _ga=GA1.2.677610765.1531824410; gadwp_wg_default_metric=sessions; gadwp_wg_default_dimension=30daysAgo; gadwp_wg_default_swmetric=sessions; session_locale=en; __stripe_mid=ca...8bd0-a33f7aa2fba1; __cfduid=d89ed...535996149; wp-settings-159=edit...tails%3Dshow; wp-settings-time-159=1541368336; intercom-id-r70azrgx=753...a1f0564c9; wp_woocommerce_session_be481d18a70...307ad9; PHPSESSID=vi...hmnjo7; woocommerce_items_in_cart=1; woocommerce_cart_hash=295dd9a8...83; wpfront-notification-bar-landingpage=1; wordpress_test_cookie=WP+Cookie+check; wordpress_logged_in_be481d18a...442=Coxxx%7C15....8d099e0dafe5bae61c1cafa91; pmpro_visit=1; _gid=GA1....693; __stripe_sid=9501...9d6f46 Upgrade-Insecure-Requests: 1 Pragma: no-cache Cache-Control: no-cache TE: Trailers RESP headers: HTTP/2.0 302 Found date: Thu, 08 Nov 2018 16:59:39 GMT content-type: text/html; charset=UTF-8 pragma: no-cache expires: Wed, 11 Jan 1984 05:00:00 GMT cache-control: no-cache, must-revalidate, max-age=0 set-cookie: woocommerce_items_in_cart=1; path=/ set-cookie: woocommerce_cart_hash=295dd...9283; path=/ set-cookie: wp_woocommerce_session_be48...1f5f82bbaa2c1f77445664307ad9; expires=Sat, 10-Nov-2018 13:53:21 GMT; Max-Age=161622; path=/ location: https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_express-checkout&useraction=continue&token=EC-7DJ.....440C host-header: 192f...2d6a8024 x-proxy-cache: BYPASS expect-ct: max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct" server: cloudflare cf-ray: 47...6a5b-LHR X-Firefox-Spdy: h2
Following the redirect, the paypal sandbox login is displayed.
Hi, I just uninstalled the plugin and reinstalled it. But I still have the same problem – however, the old config was still there after I reinstalled it so the uninstall didn’t clear everything out.
So, I found the debug file. I see that “TestMode: 1” is logged even though I have set the config to Live gateway. So the plugin config must be messed up somewhere.
I just added an invalid ‘Live API User Name’ and tried to checkout and it made no difference. I set the live user back to valid entry and I added an invalid ‘Sandbox API User Name’ and tried to checkout, I get an error returned saying ‘10002 – Security header is not valid’ even though the config is set to use the Live setting. So further evidence that the live config is not being used, only the sandbox config.
How can I uninstall and clear all old config before reinstalling?
cheers, C
Log from this mornings test:
2018-11-09T11:34:03+00:00 INFO Redirecting to PayPal 2018-11-09T11:34:03+00:00 INFO PayPal for WooCommerce Version: 1.5.3 2018-11-09T11:34:03+00:00 INFO WooCommerce Version: 3.5.1 2018-11-09T11:34:03+00:00 INFO Test Mode: 1 2018-11-09T11:34:03+00:00 INFO Endpoint: https://api-3t.sandbox.paypal.com/nvp 2018-11-09T11:34:03+00:00 INFO SetExpressCheckout Request: Array
- This reply was modified 6 years ago by colinfroggatt.
@colinfroggatt This is really interesting though as why its still saving the old value, if log is showing TEST MODE : 1 then this really means you have sandbox enabled in the express checkout settings.
I’m getting confused here with all those and would like you to submit a ticket here, include staging site details and will see what’s going on there.
Just make sure when you share staging site details, you disable all the plugins and switched the staging site theme to default twenty theme .Thanks!
Hi Oliver, Having reviewed how we want to use the plugin I realise that we are not using any of the behavior over and above what the default Woo PayPal gateway offers. My client cannot pay for more time to debug this so I have swapped back to the default Woo plugin which works as expected.
Sorry, this will have to stay as one of those weird mysteries of our local config. It worked on our staging system but refused to behave on the live platform so there is something odd between the config’s.
thanks, Colin
same problem existing with me. Paypal Express log records test mode and directs to sandbox.paypal even though using live mode.
Sorry, ignore above. I am an idiot. Tested, several times, the one product I had mistakenly ticked the “sandbox mode”
@colinfroggatt Yeah sometime its strange though. Can you also look again at the product level if , for the product you are testing, you mistakenly enabled sandbox mode and repeatedly testing the same product??? This would be the only last option to check here.
@gingeralfie Sounds great!. Its always good to debug and keep an eye on the details. That can save lots of hassle though ??
Let me know if you have any other questions or concerns.
Thanks!
Hi @oliver, @gingeralfie. I have a feeling that I may have had sandbox enabled for my test products which would explain the unexplained behavior! Unfortunately I have uninstalled the plugin so I cannot check and have no funding to go back and retest.
As a suggestion for more easily identifying this issue for other users, perhaps something could be output in the logs to indicate that sandbox mode is being picked up from the product rather than the gateway config. I see the utility of being able to define it on a per product basis but it is an unusual feature in my limited experience and so easily forgotten.
Thanks for a great support experience and next time I do a Woo setup, I’ll be back to this plugin ??
cheers, Colin
@colinfroggatt You are right and we do have a parameter in logs. When ever a user have enabled sandbox mode ( product level or settings level ) then in the transaction log TEST MODE is set to 1 ( true ) which can automatically explains that the order is placed on a sandbox environment. But we will try to improve the process even more.
Thank you so much for trusting AngellEYE products.
Cheers!
Olie
- The topic ‘Paypal Express – Live checkout goes to PP sandbox!’ is closed to new replies.