Hi,
I would like to display number of items in the cart in the header.
There is a function:
<a class="cart_dropdown_link" href="/cart/"><span aria-hidden="true" data-av_icon="" data-av_iconfont="entypo-fontello"></span><span class="av-cart-counter">0</span><span class="avia_hidden_link_text">Shopping Cart</span></a>
Every time I add something to the cart, number of items in av-cart-counter element does not change.
Could you please fix it?
Thanks
I found the fix.
I found the solution. Change
$output .= "<a class='cart_dropdown_link' href='".$link."'><span ".av_icon_string('cart')."></span><span class='av-cart-counter'>0</span><span class='avia_hidden_link_text'>".__('Shopping Cart','avia_framework')."</span></a><!--<span class='cart_subtotal'>".$cart_subtotal."</span>-->";
to
$output .= "<a class='cart_dropdown_link' href='".$link."'><span ".av_icon_string('cart')."></span><span class='av-cart-counter'>".$woocommerce->cart->cart_contents_count."</span><span class='avia_hidden_link_text'>".__('Shopping Cart','avia_framework')."</span></a><!--<span class='cart_subtotal'>".$cart_subtotal."</span>-->";
in theme/config-woocommerce/config.php
This won’t work for a child theme unfortunately.