Last active
August 29, 2015 14:01
-
-
Save galengidman/176a5306c8c31a41e555 to your computer and use it in GitHub Desktop.
Only display cart link if cart has items
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if (sizeof(WC()->cart->get_cart()) != 0) : ?> | |
<a href="<?php echo WC()->cart->get_cart_url(); ?>"> | |
<span class="cart_totals"><?php echo WC()->cart->get_cart_total(); ?></span> | |
</a> | |
<?php endif; ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment