cart/mini-cart.php

- change checked value to `$product_permalink`
- Add protocol to URLs for thumbnails in cart

Reference:
79fa19251e06c146390018984034b5a1981a78e2
8789642fb9f98466ac0729e3d9e0285e42dbb852
This commit is contained in:
Unknown 2018-06-05 20:02:35 -06:00
parent b5ecffa380
commit ce9f8dc8bd
1 changed files with 3 additions and 3 deletions

View File

@ -50,11 +50,11 @@ do_action( 'woocommerce_before_mini_cart' ); ?>
esc_attr( $_product->get_sku() ) esc_attr( $_product->get_sku() )
), $cart_item_key ); ), $cart_item_key );
?> ?>
<?php if ( ! $_product->is_visible() ) : ?> <?php if ( empty( $product_permalink ) ) : ?>
<?php echo str_replace( array( 'http:', 'https:' ), '', $thumbnail ) . $product_name . '&nbsp;'; ?> <?php echo $thumbnail . $product_name . '&nbsp;'; ?>
<?php else : ?> <?php else : ?>
<a href="<?php echo esc_url( $product_permalink ); ?>"> <a href="<?php echo esc_url( $product_permalink ); ?>">
<?php echo str_replace( array( 'http:', 'https:' ), '', $thumbnail ) . $product_name . '&nbsp;'; ?> <?php echo $thumbnail . $product_name . '&nbsp;'; ?>
</a> </a>
<?php endif; ?> <?php endif; ?>
<?php echo wc_get_formatted_cart_item_data( $cart_item ); ?> <?php echo wc_get_formatted_cart_item_data( $cart_item ); ?>