WooCommerce Visual Hook Guide: Single Product Page

Noted, ini adalah hasil copy paste dari website businessbloomer.com dan disana izinkan untuk mengcopy paste asal diberikan link sumber..


Here’s a visual hook guide for the WooCommerce Single Product Page. This is part of my “Visual Hook Guide Series“, through which you can find WooCommerce hooks quickly and easily by seeing their actual locations (and you can copy/paste). If you like this guide and it’s helpful to you, let me know in the comments!

Now that you know the product page hooks, you can override the WooCommerce Single Product Page via your child theme’s functions. You can remove default elements (for example, the featured image, the add to cart form, related products…), you can add your custom elements by picking the correct positioned “hook” and triggering your function, and you can even “move” existing elements

WooCommerce Single Product Page [Visual Hook Guide]

 

WooCommerce Single Product Page Default Actions

This is the list of WooCommerce actions you can unhook/remove by simply changing “add_action” to “remove_action” in your functions.php. WooCommerce uses its own hooks e.g. “woocommerce_before_single_product_summary” to assemble the single product page together. Because it’s done this way, you can therefore use “remove_action” to remove one of these elements. I’ve also added other “do_action” which don’t have a trigger function at the moment, but that you can use for adding content to the product page.


Link Source : https://www.businessbloomer.com/woocommerce-visual-hook-guide-single-product-page/

Leave a Reply

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