WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru
функция не описана

WC_Cart::show_shipping() public WC 1.0

Sees if the customer has entered enough data to calc the shipping yet.

Это метод класса: WC_Cart{}

Хуки из метода
Возвращает

true/false.

Использование

$WC_Cart = new WC_Cart();
$WC_Cart->show_shipping();

Код WC_Cart::show_shipping() WC 4.5.2

woocommerce/includes/class-wc-cart.php
<?php
public function show_shipping() {
	if ( ! wc_shipping_enabled() || ! $this->get_cart_contents() ) {
		return false;
	}

	if ( 'yes' === get_option( 'woocommerce_shipping_cost_requires_address' ) ) {
		$country = $this->get_customer()->get_shipping_country();
		if ( ! $country ) {
			return false;
		}
		$country_fields = WC()->countries->get_address_fields( $country, 'shipping_' );
		if ( isset( $country_fields['shipping_state'] ) && $country_fields['shipping_state']['required'] && ! $this->get_customer()->get_shipping_state() ) {
			return false;
		}
		if ( isset( $country_fields['shipping_postcode'] ) && $country_fields['shipping_postcode']['required'] && ! $this->get_customer()->get_shipping_postcode() ) {
			return false;
		}
	}

	return apply_filters( 'woocommerce_cart_ready_to_calc_shipping', true );
}