Jump to content


  • Posts

  • Joined

  • Last visited

Everything posted by alexanderbiscajin

  1. You don't have to worry about how you going to remove the add to cart buttons from shop page or any specific product page. Now you just have to follow these simple steps to disable the add to cart button from your Shop page. Add this code to woocommerce.php (located wp-content/plugins/woocommerce): function WpBlog() { removeaction( 'woocommerceaftershoploopitem', 'woocommercetemplateloopaddtocart'); removeaction( 'woocommercesingleproductsummary', 'woocommercetemplatesingleaddto_cart'); return WooCommerce::instance();} You will see that the add to cart button has been disabled. Now you can also remove or hide the button from product pages. Just put this code in functions.php addfilter('woocommerceispurchasable', 'wpblogspecific_product'); function wpblogspecificproduct($purchaseableproductwpblog, $product) { return ($product->id == specificproductid (512) ? false : $purchaseableproductwpblog); } If you still having difficulty doing the following steps you can just see that as reference https://www.wpblog.com/add-to-cart-button-in-woocommerce-store/
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.