Don't display shipping address if shipping is disabled

This commit is contained in:
Patrick Garman 2013-09-21 14:13:51 -05:00
parent f0fe86a8ac
commit 249380562a
1 changed files with 2 additions and 2 deletions

View File

@ -13,7 +13,7 @@ global $woocommerce;
$customer_id = get_current_user_id();
if ( get_option('woocommerce_ship_to_billing_address_only') == 'no' ) {
if ( get_option('woocommerce_ship_to_billing_address_only') == 'no' && get_option('woocommerce_calc_shipping') !== 'no' ) {
$page_title = apply_filters( 'woocommerce_my_account_my_address_title', __( 'My Addresses', 'woocommerce' ) );
$get_addresses = apply_filters( 'woocommerce_my_account_get_addresses', array(
'billing' => __( 'Billing Address', 'woocommerce' ),
@ -70,4 +70,4 @@ $col = 1;
<?php endforeach; ?>
<?php if ( get_option('woocommerce_ship_to_billing_address_only') == 'no' ) echo '</div>'; ?>
<?php if ( get_option('woocommerce_ship_to_billing_address_only') == 'no' ) echo '</div>'; ?>