Archived topic
WooCommerce add to cart not showing
13 replies · Started by Charles on December 7, 2020
Hi there,
I've recently installed WooCommerce and enabled the add-on within GeneratePress. However, I can't seem to get the add to cart button or price butttons on the single page.
The add to cart button appears on the shop page.
Any help would be muchly appreciated.
Charles
Hi there,
can you provide a link to a product so we cans see what the issue is?
This CSS you've added is the issue:
div.entry-summary {
display: none;
}
Let me know :)
Hi there,
Yes that fixed it, thank you.
Also, how is it possible to only show the cart in the menu when there is something added to the basket?
Charles
This article explains how to hide the empty cart:
https://docs.generatepress.com/article/hide-cart-in-menu-when-empty/
Hi there,
I've added that CSS, however, the basket is still showing in the menu.
Charles
Hmmm... can you disable your Cache/Optimizer plugin so i can take a look to see why its not applying
Sure, I've just deactivated my Siteground optimizer.
Charles
Lets try this CSS:
.mobile-bar-items.wc-mobile-cart-items:not(.has-items),
.main-navigation .wc-menu-item:not(.has-items) {
display: none !important;
}
Brilliant, that's done it, thank you. One more question, is it possible to remove the sidebar on the basket page?
Cheers
You can edit the Cart Page and use the Disable Elements module to remove the sidebar:
https://docs.generatepress.com/article/disable-elements-overview/
You can also find that same option in a Layout element if you need to remove it from archive pages:
https://docs.generatepress.com/article/layout-element-overview/
Brilliant, thanks for your help.
You're welcome