php 模板不能即时更新,php – WooCommerce 3主要更新模板错误

上周我更新到PHP 7,我也将WooCommerce更新到3.0.x.

但是在更新之后我注意到我在用户注册中的额外字段不再起作用了.我使用WP-Member插件添加了那些额外的字段.

当我进一步搜索页面底部的WooCommerce系统状态时,我发现了这个错误

customtheme/woocommerce/cart/cart.php version 2.1.0 is out of date.

The core version is 3.0.0,

customtheme/woocommerce/checkout/form-checkout.php version 2.0.0 is

out of date. The core version is 2.3.0,

customtheme/woocommerce/checkout/review-order.php version 2.1.8 is out

of date. The core version is 2.3.0,

customtheme/woocommerce/checkout/thankyou.php version 2.2.0 is out of

date. The core version is 3.0.0,

customtheme/woocommerce/content-product.php version 1.6.4 is out of

date. The core version is 3.0.0,

customtheme/woocommerce/loop/loop-start.php,

customtheme/woocommerce/loop/pagination.php,

customtheme/woocommerce/myaccount/form-edit-address.php version 2.1.0

is out of date. The core version is 2.6.0,

customtheme/woocommerce/single-product/add-to-cart/variable.php

version 2.1.0 is out of date. The core version is 2.5.0,

customtheme/woocommerce/single-product/product-image.php version

2.0.14 is out of date. The core version is 3.0.0, customtheme/woocommerce/single-product/product-thumbnails.php version

2.0.3 is out of date. The core version is 3.0.0, customtheme/woocommerce/single-product/short-description.php,

customtheme/woocommerce/single-product/tabs/description.php,

customtheme/woocommerce/single-product/title.php

任何人都可以帮我修复这些并使我的用户注册页面出现在我的所有自定义字段中

谢谢

解决方法:

WooCommerce 3.0+ is a really major update and is much more strict than before. A lot of things have changed and most of custom code used for WooCommerce version 2.6+ will need to be updated.

在您的情况下,您需要更新位于customtheme(文件夹)中的主题中的所有woocommerce模板> woocommerce(子文件夹).

为此,您必须将所有列出的文件从woocommerce插件“templates”文件夹替换为您的主题woocommerce(子文件夹):

woocommerce/templates/cart/cart.php => customtheme/woocommerce/cart/cart.php

woocommerce/templates/checkout/form-checkout.php => customtheme/woocommerce/checkout/form-checkout.php

woocommerce/templates/checkout/review-order.php => customtheme/woocommerce/checkout/review-order.php

woocommerce/templates/checkout/thankyou.php => customtheme/woocommerce/checkout/thankyou.php

woocommerce/templates/content-product.php => customtheme/woocommerce/content-product.php

woocommerce/templates/loop/loop-start.php => customtheme/woocommerce/loop/loop-start.php

woocommerce/templates/loop/pagination.php => customtheme/woocommerce/loop/pagination.php

woocommerce/templates/myaccount/form-edit-address.php => customtheme/woocommerce/myaccount/form-edit-address.php

woocommerce/templates/single-product/add-to-cart/variable.php => customtheme/woocommerce/single-product/add-to-cart/variable.php

woocommerce/templates/single-product/product-image.php => customtheme/woocommerce/single-product/product-image.php

woocommerce/templates/single-product/product-thumbnails.php => customtheme/woocommerce/single-product/product-thumbnails.php

woocommerce/templates/single-product/short-description.php => customtheme/woocommerce/single-product/short-description.php

woocommerce/templates/single-product/tabs/description.php => customtheme/woocommerce/single-product/tabs/description.php

woocommerce/templates/single-product/title.php => customtheme/woocommerce/single-product/title.php

But keep a copy of that old template before, as you will need to replace in the new templates all changes that you have maid.

标签:php,templates,wordpress,woocommerce,updates

来源: https://codeday.me/bug/20191002/1844521.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值