Tip: Easiest way to turn WooCommerce to catalog (hide add to cart button)

woocommerce-purchasable-filter

Sometimes you want to turn your WooCommerce into a product catalog. This can happen to either you or your client.

When looking for ways how to do it, you most likely stumble upon a WordPress plugin that turns on catalog mode.

I personally tried the YITH WooCommerce Catalog mode plugin and it lacked a feature that my below given solution incorporates – replacing the Add To Cart button with a Read More button. If you do not need to have a read more button instead of the add to cart button, YITH’s plugin is your right choice.

BUT

If you want to turn the WooCommerce shop to a catalog so that in the category view the products have a read more button instead of add to cart button, just add this line of code in your theme’s functions.php.

/* remove add to cart button */
add_filter( 'woocommerce_is_purchasable', '__return_false');

This is working in WordPress 5.0.3 and WooCommerce 3.4.4 versions.

Personally I don’t see a reason to add another plugin to bulk up your WordPress if you would be fine with the read more button and can handle editing functions.php (of your preferably, most recommendedly, child theme).

This helped me turn a customer’s WooCommerce e-shop to an online catalog.

Post Author: Tom Pai