Skip to content

Commit cda538a

Browse files
committed
- **Tweak** - WooCommerce: replace deprecated WC_Cart::get_cart_url by wc_get_cart_url()
1 parent e8a971e commit cda538a

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

footer.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@
9090
if (current_theme_supports( 'woocommerce')) : ?>
9191
<ul class="nav navbar-nav navbar-right navbar-shoppingcart <?php echo (WC()->cart->get_cart_contents_count() == 0?'navbar-shoppingcart-empty':'navbar-shoppingcart-notempty'); ?> site-header-cart menu">
9292
<li>
93-
<a class="cart-contents" href="<?php echo esc_url(WC()->cart->get_cart_url()); ?>" title="<?php esc_attr_e(
93+
<a class="cart-contents" href="<?php echo esc_url(wc_get_cart_url()); ?>" title="<?php esc_attr_e(
9494
'View your shopping cart', 'stormbringer'
9595
); ?>">
9696
<span class="amount"><?php echo wp_kses_data(WC()->cart->get_cart_subtotal()); ?></span>

inc/plugins/woocommerce.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,7 @@ function stormbringer_handheld_footer_bar_search() {
341341
*/
342342
function stormbringer_handheld_footer_bar_cart_link() {
343343
?>
344-
<a class="footer-cart-contents" href="<?php echo esc_url( WC()->cart->get_cart_url() ); ?>" title="<?php esc_attr_e(
344+
<a class="footer-cart-contents" href="<?php echo esc_url( wc_get_cart_url() ); ?>" title="<?php esc_attr_e(
345345
'View your shopping cart', 'stormbringer'
346346
); ?>">
347347
<span class="glyphicon glyphicon-shopping-cart"></span>
@@ -489,7 +489,7 @@ function woocommerce_cart_count_shortcode( $atts ) {
489489
)
490490
).')';
491491
}
492-
$link_url = esc_url(WC()->cart->get_cart_url());
492+
$link_url = esc_url(wc_get_cart_url());
493493
} else {
494494
$woocommerce_shop_page_id = get_option( 'woocommerce_shop_page_id' );
495495
$link_url = get_permalink( $woocommerce_shop_page_id );

scss/helpers/_common.scss

+3
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,9 @@ iframe{border: 0}
9090
.bootstrap-select a:focus{
9191
outline: 0 !important;
9292
}
93+
.bootstrap-select:not([class*=col-]):not([class*=form-control]):not(.input-group-btn){
94+
width: auto;
95+
}
9396

9497
// Comments
9598
.edit-comment{

0 commit comments

Comments
 (0)