Woocommerce template single-product.php in theme folder not working

admin2025-06-04  2

single-product.php not working for single products. I do not have woocommerce.php file in my theme but still single.php executing for single products. This is a custom theme and when i change my theme name to twentyten then single-product.php started to execute but when i change its name to something else (custom theme name) than this template does not work at all and instead it execute single.php Any suggestion will be much appreciated.

single-product.php not working for single products. I do not have woocommerce.php file in my theme but still single.php executing for single products. This is a custom theme and when i change my theme name to twentyten then single-product.php started to execute but when i change its name to something else (custom theme name) than this template does not work at all and instead it execute single.php Any suggestion will be much appreciated.

Share Improve this question asked Mar 23, 2018 at 12:03 wpddwpdd 3134 silver badges15 bronze badges 4
  • Why are you posting this again? It's been less than a day. Besides, it's about a 3rd-party plugin and off-topic. Please see the WooCommerce developer documentation for supporting WooCommerce in your theme. – Jacob Peattie Commented Mar 23, 2018 at 12:08
  • I was not able to get any response on this issue that is why i post this again. If this is off-topic then why woocommerce tag is available ? – wpdd Commented Mar 23, 2018 at 12:10
  • Firstly, 15 hours is not enough time to say you didn't get a response. Secondly, when you select WooCommerce as a tag a box literally appears right under it that says "OFF TOPIC. Questions specific for this e-commerce plugin have their own forum at wordpress/support/plugin/woocommerce.". – Jacob Peattie Commented Mar 23, 2018 at 12:14
  • 1 Possible duplicate of single-product.php template not working for single products – Jacob Peattie Commented Mar 24, 2018 at 2:57
Add a comment  | 

1 Answer 1

Reset to default 2

I add this line in my theme's functions.php file and now everything working fine.

add_theme_support( 'woocommerce' );
转载请注明原文地址:http://conceptsofalgorithm.com/Algorithm/1748968406a315241.html

最新回复(0)