wordpress - Woocommerce 模板覆盖不起作用

标签 wordpress woocommerce wordpress-theming woocommerce-theming

我想从我的主题中覆盖 woocommerce 模板。我遵循 woocommerce 官方文档中的所有步骤。而且我确定我的主题中没有 woocommerce.php 文件。
所以,我不明白为什么它不起作用。
我正在使用二十七主题。

任何帮助将不胜感激。

最佳答案

如果您已经阅读过这些文件
https://docs.woothemes.com/document/template-structure/

Please Note: When creating woocommerce.php in your theme’s folder, you will be unable to override the woocommerce/archive-product.php custom template in your theme, as woocommerce.php has priority over all other template files. This is intended to prevent display issues.



还要确保您没有激活“模板 Debug模式”,您可以在以下位置找到:

WP 仪表板 -> WooCommerce -> 系统状态 -> 工具

关于wordpress - Woocommerce 模板覆盖不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45848547/

相关文章:

wordpress - Woocommerce 显示默认变化价格

css - 在 wordpress 中创建固定标题

php - 在产品销售时将自定义文本标签添加到价格

php - 覆盖 WooCommerce 类别列表 Walker 的最佳方法

html - 如何修复 header 在 wordpress 中不粘?

php - 如何为 wordpress WP_QUERY 清理 $_POST?

php - 如何更改小部件菜单容器

css - 在 WordPress 帖子中将文本宽度设置为 75%,将图像宽度设置为 100%?

tags - WordPress 网站帖子被重定向到 Youtube 视频

wordpress - WooCommerce - 重命名/product/和/product-category/slugs