Woocommerce product-category overriding

Viewed 8464

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-category/parfyumeriya/ shows the list of product in this category but it uses standart template. I want to use my own template, but I don't know which files of plugin's template should I edit. I tried content-product_cat.php, taxonomy-product_cat.php, archive-product.php, but nothing is working. Any ideas?

1 Answers

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

Related