Strange session issue with Woocommerce

I’m trying to get WooCommerce up and running on a basic site, and I’m having a problem with the cart.

Basically, when I’m logged in as admin, everything works as expected. But when I’m not logged in, I can add an item to the cart, but the cookies immediately disappear, thereby stopping the cart from working at all… It seems like the session is being reset by either WooCommerce or WordPress every time a WooCommerce page is visited by a guest.

Read More

This is a big problem, as I don’t want anyone to be signing up for accounts to buy my single product.

Does anyone know what could be causing this, and how to fix it? I’ve looked through the WooCommerce code, and I can’t see anything but the init method of the $woocommerce global calling the methods that set the cookies… And the cookies themselves are set to be deleted when the browser closes, but they are being overwritten as soon as the cart page loads.

Related posts

Leave a Reply

2 comments

  1. I just ended up installing JigoShop. Needed some CSS tweaks to work with TwentyTwelve, but it allows people to buy stuff, which is more than WooCommerce has done for me 😉

  2. We had the same problem on https://sherpax.cz ecommerce store. Go to plugins, and remove all caching plugins (Comet cache, etc.). There was an issue with session mixing even if Comet cache was set up properly not to cache particular pages (cart, etc.).