Tips and Tricks HQ Support Portal › Forums › WP eStore Forum › WP eStore Troubleshooting › Empty Shopping Cart Error When Checking Out with PayPal
Tagged: back, button, cart, checkout, clears, empty cart, PayPal, PHP Session, return
- This topic has 13 replies, 7 voices, and was last updated 13 years, 2 months ago by admin.
-
AuthorPosts
-
November 11, 2010 at 5:42 pm #2211fudgenaroundMember
Something weird is happening. with certain items during the checkout the cart is lost and I get the following message:
Either your shopping cart is empty or the PHP Session on your server is not working correctly. Please check this article
This happens when I add certain products to the cart only. I was working on the cart yesterday and it was fine and today I am getting this error. I am using FireFox 3.6.12. When I try to place an order with another browser such as Chrome or IE it works fine.
Here is the website: http://fudgenaround.com/index.php/order-fudge/
If I add Chocolate Brick and check out it is fine but if I add Mint Brick and checkout it thinks my shopping cart is empty.
Any clue? I know the PHP Session is working cuz I host dozens of websites that use it on the same server. I’m running IIS6 on Win2k3 Server. I’m thinking there is something funky going on with the browser but not sure why it happens only with certain products
November 16, 2010 at 4:49 am #26418amin007ParticipantMy apologies for missing this post.
Lets try this tweak first to make sure that the issue is related to what I think it is:
Open the “eStore_payment_submission.php” file and search for the following line of code:
reset_eStore_cart();
When you find it just delete it (there will be a few occurrences so delete them all).
Now do a checkout and let me know how it behaves. yes the cart will not get cleared after the purchase but I have a solution for that.
November 16, 2010 at 4:23 pm #26419fudgenaroundMemberI commented out all the calls to reset_eStore_cart() on eStore_payment_submission.php but the issue is still happening in FireFox. I didn’t delete the lines incase we had to put them back in there but they are still currently disabled on the website. I commented out the check function that checks if session is working or if the cart is empty and when it went to paypal the shopping cart was actually empty.
Any other ideas?
November 16, 2010 at 4:32 pm #26420fudgenaroundMemberokay, something weird is happening. I logged out as admin and then tried the shopping cart and now I am able to check out. I went through and removed all the comments to the reset cart function and tried it again and I am able to check out. I also logged back in as admin and tried the cart again and no problems now.
not sure how I got stuck but it seems to be working now on all browsers and FireFox too.
November 17, 2010 at 1:22 am #26421amin007ParticipantI can’t really explain it just yet as I haven’t been able to identify a pattern so please keep an eye out to see what changes in the server causes this weird behavior.
November 18, 2010 at 1:12 am #26422fudgenaroundMemberI almost think its a browser/cookie issue cuz it went away as soon as I logged out as admin and on the other browsers Chrome and IE i never logged in as admin
November 21, 2010 at 4:38 pm #26423fudgenaroundMemberokay… its back! When using FF, I added some items to the cart and when I went to go check out the cart was empty. I thought it was the admin logged in thing again and logged out and cleared out the cart. added new items and when i clicked on check out was getting the empty cart message again.
any ideas on how to track this bug down?
November 22, 2010 at 12:58 am #26424wpCommerceModeratorOk, I just jumped on your order page – http://fudgenaround.com/index.php/order-fudge/
After adding a product to the cart I clicked on checkout and it was trying to submit all the product information from – http://www.fudgenaround.com/wp-content/plugins/wp-cart-for-digital-products/eStore_payment_submission.php
You can see that there is a difference between the two URL. One has www and another doesn’t have.
we added product from the URL with no WWW but during checkout eStore is trying submit data from the 2nd URL (where no product has been added resulting an empty cart error). I guess you are using www version for WP URL and no www for the site URL. Please make sure the WP URL and the site URL are same in your General settings of WordPress.
The cause and effect is explained in detail here:
November 22, 2010 at 10:03 pm #26425fudgenaroundMemberthat was it! damn URLs. I had the entry for the products page as “/index.php/order-fudge/” and now I updated it to “http://www.fudgenaround.com/index.php/order-fudge/” to make sure the www is in the URL now.
Thank you so much for helping me. it was drivin me nutz and I couldn’t figure it out.
January 5, 2011 at 9:38 pm #26426teamilluminatiMemberI just finished reading this earlier post:
“Lets try this tweak first to make sure that the issue is related to what I think it is:
Open the “eStore_payment_submission.php” file and search for the following line of code:
reset_eStore_cart();
When you find it just delete it (there will be a few occurrences so delete them all).
Now do a checkout and let me know how it behaves. yes the cart will not get cleared after the purchase but I have a solution for that.”
Amin, can you please describe what that solution is?
thanks,
Ernest
January 5, 2011 at 9:49 pm #26427teamilluminatiMemberoops! sorry, i forgot to include the URL where i’m having the issue. it’s a site i’m building that’s currently in sandbox mode, at http://latinhymns.com/store
the problem only appears in firefox. i have already changed my eStore_payment_submission.php file as you recommended, and that seemed to clear up the issue. however, now the shopping cart remains full even after checkout.
thanks,
ernest
April 5, 2011 at 2:25 pm #26428bastywebbSpectatorI didn’t like the fact that, if a user clicked the back button or the ‘cancel and return to merchant’ link on paypal their cart would be empty. So I followed the advice here and went to the eStore_payment_submission.php file and commented out all 3 occurrences of:
reset_eStore_cart();
My solution to ensuring that the cart eventually gets cleared when payment is complete was to put the reset_eStore_cart() function at the top of my thank you page. To do that, I created a file in my theme called page-thank-you.php which was a copy of page.php. My slug for the thank you page is thank-you, so anyone else would adapt the name of the file like so page-your-thank-you-page-slug.php
September 5, 2011 at 3:22 am #26429dlavineMemberNone of the solutions that I’ve found so far work. Can someone please tell me why the cart empty error is happening at the following location online: http://www.sweettaterpiepublishing.com/wordpress/?page_id=2
September 5, 2011 at 8:07 am #26430adminKeymasterUncheck the “Use Fancy Redirection on Checkout” option from the eStore settings and try it out.
-
AuthorPosts
- You must be logged in to reply to this topic.