darrenultra Posted April 4, 2011 Share Posted April 4, 2011 Hi, A customer has recently reported that when using the 'Straight to Checkout' option in the Purchase Without Account contribution, that the checkout_shipping_address.php page shows the addresses of previous PWA customers. Instead of being given the option to enter a new address he is presented with a list of PWA customers addresses and asked to choose one. Strangely enough this only happens on my live website. On my local server PWA works as it should. This leads me to believe that something about my live (SSL) url is causing the PWA malfunction: Live Website https://sslrelay.com/mywebsite.co.uk/checkout_shipping_address.php?osCsid=81ddf75b056a71f7eb249a2e92875163 Local Server http://www.localdevelopmentserver.com/mywebsite/checkout_shipping_address.php I have triple checked and my checkout_shipping_address.php pages are identical on my local and live websites. Anyone have any idea what is going on? Any help will be much appreciated. Quote Link to comment Share on other sites More sharing options...
Guest Posted April 4, 2011 Share Posted April 4, 2011 Nick, I would check the sessions settings in admin. The last two lines should appear like this: Prevent Spider Sessions True Recreate Session True If that does not resolve the issue, check your PWA installation as I believe there should be a line of code to clear the session (sorry, I don't remember where it is). Chris Quote Link to comment Share on other sites More sharing options...
darrenultra Posted April 4, 2011 Author Share Posted April 4, 2011 Hey Chris, Thanks for the help. My session settings are ok in admin ...so I guess I'm missing the code to end the session. I've googled for similar problems but i'm not coming up with much. If you have any ideas let me know. Many thanks Nick Nick, I would check the sessions settings in admin. The last two lines should appear like this: Prevent Spider Sessions True Recreate Session True If that does not resolve the issue, check your PWA installation as I believe there should be a line of code to clear the session (sorry, I don't remember where it is). Chris Quote Link to comment Share on other sites More sharing options...
darrenultra Posted April 6, 2011 Author Share Posted April 6, 2011 Ok ...after taking a closer look at the customer addresses appearing on the checkout_shipping_address.php page I can see that they are not past PWA customers. I assumed that this was the case because each has a customer_id of 0. However, they are actually Paypal Express Checkout IPN customers (who are also given the customer_id of 0). Any ideas how I might adapt PWA such that these customer addresses do not appear? Quote Link to comment Share on other sites More sharing options...
darrenultra Posted April 6, 2011 Author Share Posted April 6, 2011 I've now figured this out. I had to update ec_shipping.php such that it contained PWA modifications (use a file compare program). I also had to update a function in includes/functions/general.php. The modded function is shown below: function tep_count_customer_address_book_entries($id = '', $check_session = true) { global $customer_id; if (is_numeric($id) == false) { if (tep_session_is_registered('customer_id') and $customer_id != '0') { $id = $customer_id; } else { return 0; } } I hope this helps anyone with both PWA and Paypal Express Checkout IPN installed. Quote Link to comment Share on other sites More sharing options...
Guest Posted April 6, 2011 Share Posted April 6, 2011 Hi Nick, I knew that it had a session clearing function somewhere, sorry I was not able to pin point it for you but now that you have it in the right place hopefully it will work well for you. Chris Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.