More formatting

Identical to Woo files. Again, this is important to better sync with standard Woo files, making future updates easier.
This commit is contained in:
Unknown 2018-03-22 14:02:03 -06:00 committed by zachary
parent 4fd0028cc6
commit 273c936fb3
1 changed files with 13 additions and 15 deletions

View File

@ -74,23 +74,21 @@ do_action( 'woocommerce_before_cart' ); ?>
} }
?></td> ?></td>
<td class="product-name" data-title="<?php esc_attr_e( 'Product', 'understrap' ); ?>"> <td class="product-name" data-title="<?php esc_attr_e( 'Product', 'understrap' ); ?>"><?php
<?php
if ( ! $product_permalink ) { if ( ! $product_permalink ) {
echo apply_filters( 'woocommerce_cart_item_name', $_product->get_name(), $cart_item, $cart_item_key ) . '&nbsp;'; echo apply_filters( 'woocommerce_cart_item_name', $_product->get_name(), $cart_item, $cart_item_key ) . '&nbsp;';
} else { } else {
echo apply_filters( 'woocommerce_cart_item_name', sprintf( '<a href="%s">%s</a>', esc_url( $product_permalink ), $_product->get_name() ), $cart_item, $cart_item_key ); echo apply_filters( 'woocommerce_cart_item_name', sprintf( '<a href="%s">%s</a>', esc_url( $product_permalink ), $_product->get_name() ), $cart_item, $cart_item_key );
} }
// Meta data // Meta data.
echo wc_get_formatted_cart_item_data( $cart_item ); echo wc_get_formatted_cart_item_data( $cart_item );
// Backorder notification // Backorder notification.
if ( $_product->backorders_require_notification() && $_product->is_on_backorder( $cart_item['quantity'] ) ) { if ( $_product->backorders_require_notification() && $_product->is_on_backorder( $cart_item['quantity'] ) ) {
echo '<p class="backorder_notification">' . esc_html__( 'Available on backorder', 'understrap' ) . '</p>'; echo '<p class="backorder_notification">' . esc_html__( 'Available on backorder', 'understrap' ) . '</p>';
} }
?> ?></td>
</td>
<td class="product-price" data-title="<?php esc_attr_e( 'Price', 'understrap' ); ?>"> <td class="product-price" data-title="<?php esc_attr_e( 'Price', 'understrap' ); ?>">
<?php <?php