- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
This just started happening on our 2.3.3 CE live server.
We have found 2 grouped product pages (so far, no other products seem to cause this problem), that if you already have products in your inbox, and simply load these product pages, the cart gets emptied.
Loading other products don't seem to have this problem. I have tried re-creating one of the products, but it continues to happen with that page.
What is especially confusing, is that we have 2 store_views (english and french), and this problem only happens on the english side. The problem does not happen on the French side.
Has anybody seen this problem before?
Solved! Go to Solution.
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
So in fact it was a very weird bug (I havn't had time to test in vanilla Magento, so it could be my environment).
If a product had an image url within the product description that contained "/pub/media/..." it would cause this problem. If I removed the "/pub" and left it as "/media/..." then the problem stopped, and the image loaded (assuming it still existed). This was a carry forward from converting our product descriptions from an older e-commerce engine (NopCommerce) to Magento 2.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: Cart is being emptied when certain product pages are loaded. help
Hi @oliver_bishop
Might be there are any event observer for the same sku in any custom module to truncate the cart.
Change the SKU once for the same products and try once.
Then re-indexing and flush the cache.
php bin/magento indexer:reindex php bin/magento cache:flush
Might be it help you!
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: Cart is being emptied when certain product pages are loaded. help
I have actually tried re-creating the grouped product with a different SKU, and a new url, and the same problem happens. I'm thinking it has to do with one of the child SKU's, but there is a lot under this grouped SKU, so Its tedious to re-create them.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: Cart is being emptied when certain product pages are loaded. help
It might be possible with associated products as well.
For now you can create a duplicate product of it with different sku.
Remove the associated products in few bunches and check. Then you find the real product which is creating issue.
For example: first remove or disable all products of that group product, then few etc
I hope it might help you to find out the root cause.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
So in fact it was a very weird bug (I havn't had time to test in vanilla Magento, so it could be my environment).
If a product had an image url within the product description that contained "/pub/media/..." it would cause this problem. If I removed the "/pub" and left it as "/media/..." then the problem stopped, and the image loaded (assuming it still existed). This was a carry forward from converting our product descriptions from an older e-commerce engine (NopCommerce) to Magento 2.