This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.
WooCommerce: Post Title missing from Product page
If certain Product information is missing from your WordPress theme with WooCommerce support, this code snippet will help.
If you’re working on a custom WordPress theme with WooCommerce support, you may be using template overrides by copying WooCommerce templates from the Plugins directory to your theme directory. If this is the case, then you might discover that certain information is missing from your Product pages (on a template like single-product.php
).
To resolve this, simply add the following code snippet to your functions.php file or equivalent. The WooCommerce Theme Developer Handbook outlines that “WooCommerce template overrides are only enabled on themes that declare WooCommerce support”, so by declaring WooCommerce support on your theme, your templates should start behaving correctly.
function barebones_add_woocommerce_support() {
add_theme_support( 'woocommerce' );
}
add_action( 'after_setup_theme', 'barebones_add_woocommerce_support' );