Showing results for 
Search instead for 
Did you mean: 

Customers Cannot Add Products to Cart After Cookie Changes

Customers Cannot Add Products to Cart After Cookie Changes

This week, I was adjusting the Cookie Lifetime in our Magento 1.9 site. I also adjusted the session.cookie_lifetime values in the php.ini file (php version 5.6).

Cookie Lifetime (original value) = 259200
Cookie Lifetime (new value) = 1296000

session.cookie_lifetime (original value) = 0
session.cookie_lifetime(new value) = 86400

After those changes were implemented my sales team notified me that they couldn't place items in the Magento Cart. I quickly figured out that if the sales team cleared their browser cookies this issue was solved.

The next day, customers started calling in with this same issue - when they tried to add products to their shopping cart, they would see "shopping cart empty" and the product would never add to their cart. I also had customers who couldn't login to their accounts.

I reversed the Cookie Lifetime and session.cookie_lifetime values to their original values and cleared Magento Cache and reindexed the Magento site. The calls continued to come in. The only solution that I've been able to use to "fix" this is to have the user clear their browser cookies.

My problem is our customers are not very technical and walking them through this solution is often frustrating for the customer and they just hang up. I'm also not able to reach the customers who don't reach out to us for help.

Per the changes I made - what exactly caused this issue? It looks like there is some sort of cookie conflict happening. How do I go about getting this resolved for all customers so they don't have to contact us for help?


Re: Customers Cannot Add Products to Cart After Cookie Changes

If reverting it to the original value isn't working, it sounds like you may have to ride this one out as all the original cookies should expire after 72 hours.
James Lee | Moderator • Magento Master
See My Recommended Magento Hosting & Security Tips