Tips and Tricks HQ Support Portal › Forums › WP eStore Forum › WP eStore F.A.Q/Instructions › PHP Session not Working Correctly
Tagged: caching, CDN, check out page, permission denied (13), PHP Session, php session error, php session issue, PHP session not working, php warning, session_start, W3 Total Cache, web hosting
- This topic has 68 replies, 24 voices, and was last updated 8 years, 10 months ago by wzp.
-
AuthorPosts
-
May 15, 2010 at 9:14 am #1204amin007Participant
A shopping cart plugin or a membership plugin will exhibit strange behavior if PHP session on your server is not working correctly. It is your hosting provider’s duty to give you a correctly setup server where PHP session is working properly. Sometimes the session problem can come from a bad plugin that you may have installed on your site.
This post will help you pinpoint the source of the PHP session related issue (if you have one) so you can address it.
How To Find Out If You Are Having a PHP Session Related Issue
This simple test should help you identify if you are having PHP Session issue on your server.
Step 0: Make sure to empty the cache and deactivate any caching plugin before you do this test.
Step 1: Add a product to the shopping cart (Check to make sure that the item is in the cart)
Step 2: Now browse to a different page on your site (any page will do).
Step 3: Go back to the page where you have your shopping cart that shows you the items in your cart. Can you see still the item that you added in step 1?
If you can see the item in the cart after step 3 then your PHP Session is most likely working fine.
If you cannot see the item the cart after step 3 then that means your PHP Session is not storing the data like it is supposed to. The PHP session is losing the value when you do another operation (step 2 in this case).
How to Solve The Issue
The following plugin can be a quick fix on some sites where the PHP session functionality is broken:
If this plugin doesn’t solve the issue then it needs to be investigated further.
Once you identify that your site is showing the above mentioned PHP Session problem, you need to find out the source. The following checklist should help with that:
Preparation
Turn off any caching plugin (if you have one) while you do the following checks.
1. Issue related to PHP session setup
Occasionally a server may not have it’s PHP session configured correctly. Please note that you won’t be able to use a shopping cart software without the PHP session working correctly. It is your hosting provider’s responsibility to give you a server where the PHP session is setup properly. Contacting your hosting provider and requesting them to fix it is a good idea.
Making the PHP session to work is not very hard. You mainly have to make sure the following two things are in place:
1) Check if your server’s PHP config is set to allow sessions.
2) Check to make sure the session save path has been configured correctly. This is just a matter of adding a line similar to the following in the php.ini file:
session.save_path = /tmp
It is best to contact your hosting provider so they can do this for you. All you have to do is request them to fix the PHP session issue on your server and they should know what to do.
2. Issue related to using a bad plugin that is messing up the PHP session
There are a few plugins out there that are not coded correctly and messes up the PHP session on your site when they are installed. I have seen a few plugins that creates a new PHP session without checking for an existing one first which can cause this issue. Do the following test to identify if you have a bad plugin like this so you can delete that plugin:
3. Issue related to incorrect server setup
Please check this article that explains how this issue can come from incorrect server setup (check the 2nd point):
Resources
The following topics are good examples of how other users (who faced this issue) fixed the issue:
https://wordpress.org/support/topic/the-loopback-request-to-your-site-failed-4/page/2/#post-10662220
Find Out Which WordPress Web Hosting Company Offers the Cheapest and Reliable Web Hosting Solution
October 5, 2010 at 3:37 pm #20524crossMemberThis is concerning WP eStore, installed with WordPress 3.0.1.
I am getting the “Either your shopping cart is empty or the PHP Session on your server is not working correctly.” error page when attempting to checkout with PayPal. This ONLY happens in FireFox when following these steps:
1. Adding an item to cart
2. Emptying the cart or deleting the item from cart
3. Adding another item to cart
4. Clicking on the Checkout with PayPal button
I have tried the same sequence of steps in IE, and there are no errors — I get sent to the PayPal checkout page just fine.
URL of pricing/order page:
[http://www.thecreativecafe.net/pricing/]
Thank you for your assistance!
October 5, 2010 at 8:28 pm #20525wzpModeratorUsing Firefox 3.5.5
1. Added “Silver” package.
2. Deleted item from cart.
3. Added “Blue” package.
4. Click on the Checkout with PayPal button.
Got the …please wait… screen.
Got “non-enhanced” PayPal checkout screen.
1. Added “Gold” package.
2. Emptied cart.
3. Added “Silver” package.
4. Click on the Checkout with PayPal button.
Got the …please wait… screen.
Got “enhanced” PayPal checkout screen.
Are you using a hosting provider, or using your own server? What version of PHP is the server running?
October 6, 2010 at 12:49 am #20526amin007ParticipantYou seem to have made some modifications to the plugin which broke it. Did you try it with a fresh unmodified version just to see the difference?
https://support.tipsandtricks-hq.com/forums/topic/re-install-or-load-a-fresh-build-of-the-plugins
October 29, 2010 at 11:24 pm #20527JakeyMemberAre there issues with the eStore plugin and FF 3.6.12?
I’m getting the message “Either your shopping cart is empty or the PHP Session on your server is not working correctly. Please check this article”, only in FF.
I don’t get that message in Chrome, Opera or IE.
Thanks!
Jake
October 30, 2010 at 12:44 am #20528JakeyMemberI just checked and it works in Safari too.
The strange thing is that it has worked fine in Firefox for the last couple months..
Really weird.
October 30, 2010 at 9:18 am #20529amin007ParticipantPlease post a link to the page.
October 30, 2010 at 4:26 pm #20530JakeyMemberHi, Turned out a hosting problem. My host fixed it up and now everything is working fine.
Sorry for wasting your time.
Thank You,
Jake
November 4, 2010 at 11:30 pm #20531iinetMemberI am getting this same error only in Firefox 3.6? Please help. I’m trying to get ready for a launch. Thanks!
ERROR
Either your shopping cart is empty or the PHP Session on your server is not working correctly. Please check this article
November 5, 2010 at 4:22 am #20532amin007ParticipantLets try the following option and see how it goes:
Go to
eStore Settings -> Advanced Settings
menu and then check the following option and save it:Enable Alternate Redirection Method
Now, do a checkout and let me know how you go.
November 8, 2010 at 1:35 am #20533David KakonMemberI get this:
Either your shopping cart is empty or the PHP Session on your server is not working correctly. Please check this article
November 9, 2010 at 12:17 am #20534amin007ParticipantI will send you an email to get site access to check this out.
November 10, 2010 at 4:42 am #20535amin007ParticipantTurned out that you had an incorrect server setup explained here (check the 2nd point):
https://support.tipsandtricks-hq.com/forums/topic/paypal-says-your-shopping-cart-is-empty
December 22, 2010 at 10:58 pm #20536otherrecordsMemberI’ve setup eStore and have been using Sandbox for testing.
But now, I’m getting this error when I try to proceed with Check Out to PayPal.
“Either your shopping cart is empty or the PHP Session on your server is not working correctly. Please check this article
https://support.tipsandtricks-hq.com/forums/topic/php-session-not-working-correctly
December 23, 2010 at 12:05 am #20537wpCommerceModeratorCan you please post a link to the page where I can test the checkout?
-
AuthorPosts
- You must be logged in to reply to this topic.