Woocommerce product-category overriding

后端 未结 1 1172
面向向阳花
面向向阳花 2021-01-20 04:41

I have a problem overriding standat Woocommerce template. I have a product category named \"Parfyumeriya\" on my website, so the link http://localhost/mywebsite/product-cate

相关标签:
1条回答
  • 2021-01-20 05:35

    If the template you want to replace or override belongs to woocommerce you will find it in the wp-content/plugins/woocommerce/templates.

    To override it you have to create a folder in your child-theme also named woocommerce and copy the file (whole path inside templates) there where you can edit it and make changes to it.

    For example:

    plugins/woocommerce/templates/taxonomy-product_cat.php will be copied as themes/your_child_theme/woocommerce/taxonomy-product_cat.php

    Regarding having a specific template for a product category the comment in the selected answer of this question says how to name the file:

    taxonomy-product_cat-{slug}.php

    Woocommerce - Specific template for product category?

    Here there is a link to woocommerce docs

    0 讨论(0)
提交回复
热议问题