I'm trying to override single-product.php.
I have put a copy in:
yourtheme/woocommerce/single-product.php (i'm using Dynamic website builder based on Genesis)
But it still uses the version in woocommerce-views/templates
If i rename that one, it works. Then it uses the one in yourtheme/woocommerce/
But that's no good, because the next update of WooCommerce Views will create a new version, right?
Hello,
Thanks for contacting Toolset support.
Generally, yes - when you update it it will use the file you renamed. But I can't think of any other solution then to rename the file when there is an update, as this is designed to use the one from woocommerce-views
Thanks.
I don't really understand the point of of putting it in yourtheme/woocommerce/ if i have to do a fix anyway every time there is an update?
Then i can just as well do the fix in woocommerce-views/templates?
Why even having this line in the header in single-product.php:
"* Override this template by copying it to yourtheme/woocommerce/single-product.php"
Are there really no way of avoiding the fix with every update? I mean, most of my clients will never be able to do that themselves in the future.
Hello,
There is a reason for sure why developers had this approach, although I am not certainly aware of it.
Maybe to make it easier for the customers, you can create .php file called for example "fix-it.php", and then give them get_template_part code and tell them where to place it inside the updated file?
Thanks.