Before you can alter Woocommerce , you have to do is install the WooCommerce plugin. You can download it for nothing from the WordPress store.

Reign theme

I will presently examine how to hide, evacuate or remove the Add to Cart button on WooCommerce shop pages. There are numerous reasons why WooCommerce storekeepers can incidentally or for all time cripple include truck button their site, for example, an item is out of stock.

Go to the WooCommerce store and add an product. Give it a name and attempt to fill whatever number subtleties as could be expected under the circumstances for this test item.

remove add to cart button

In the frontend of the store, you will presently observe the product detail page.

Remove the Add to Cart Button in WooCommerce.

I will currently exhibit how to remove this button from item detail page and the shop page (item posting page). For this, we’ll add the following hooks:

[php]

<code>remove_action( ‘woocommerce_after_shop_loop_item’, ‘woocommerce_template_loop_add_to_cart’);</code>
<code>
remove_action( ‘woocommerce_single_product_summary’, ‘woocommerce_template_single_add_to_cart’);</code>

[/php]

The beneficial thing about these hooks is that you could put them anyplace suitable. The basic practice is to remember these snares for functions.php which is situated in your topic organizer. Notwithstanding, this may cause blunders at times. I will, thusly, place these snares in woocommerce.php (found in the plugin folder).

To get to this document, of to WordPress > wp-content > plugin > woocommerce > woocommerce.php.

[php]

<code>function wbcomdesign() {
remove_action( ‘woocommerce_after_shop_loop_item’, ‘woocommerce_template_loop_add_to_cart’);
remove_action( ‘woocommerce_single_product_summary’, ‘woocommerce_template_single_add_to_cart’);
return WooCommerce::instance();</code>

[/php]

When done, cave the document and revive the page. When the page loads, you will see that the Add to Cart button has been revoved from the page.

Free Remove Add to Cart WooCommerce Plugin:

This Plugin performs following capacities

1-Remove/Disable Add to Cart from Complete Category.

2-Replace Add to Cart button with Inquire Us from Complete Category.

3-Remove Add to truck from singular Product pages.

4-Replace Add to truck with Inquire us from item pages.

5-Hide cost from Complete Category

6-Hide Price per Product

woocommerce add to cart  setting

 

Also read: How to Enable Product Enquiry Form in Single Product Page in WooCommerce?

Leave a Reply

Your email address will not be published. Required fields are marked *