1
woocommerceの送料に問題があります。ここにはカートのページに表示されるエラーがあります。致命的なエラーget_label()woocommerceの送料
Fatal error: Call to a member function get_label() on null in public_html/wp-content/plugins/woocommerce/includes/wc-cart-functions.php on line 327
WC-カートのfunctions.php
function wc_cart_totals_shipping_method_label($method) {
$label = $method->get_label();
if ($method->cost > 0) {
if (WC()->cart->tax_display_cart == 'excl') {
$label .= ': ' . wc_price($method->cost);
if ($method->get_shipping_tax() > 0 && WC()->cart->prices_include_tax) {
$label .= ' <small class="tax_label">' . WC()->countries->ex_tax_or_vat() . '</small>';
}
} else {
$label .= ': ' . wc_price($method->cost + $method->get_shipping_tax());
if ($method->get_shipping_tax() > 0 && ! WC()->cart->prices_include_tax) {
$label .= ' <small class="tax_label">' . WC()->countries->inc_tax_or_vat() . '</small>';
}
}
}
return apply_filters('woocommerce_cart_shipping_method_full_label', $label, $method);
}
get_label()
public function get_label() {
return apply_filters('woocommerce_shipping_rate_label', $this->label);
}
すべてのヘルプは高く評価されるであろう。
問題の原因となっているコード部分を貼り付けてコピーできますか? line 320〜line 335 –
質問が更新されました – Kevin
検索woocommerceファイルとget_label()の本文を検索 –