neilgee
9/25/2015 - 12:03 AM

WooCommerce - Checkout link (when cart is not empty)

WooCommerce - Checkout link (when cart is not empty)

global $woocommerce;

if ( sizeof( $woocommerce->cart->cart_contents) > 0 && !is_cart() && !is_checkout() ) :
	echo '<a href="' . $woocommerce->cart->get_checkout_url() . '" title="' . __( 'Checkout' ) . '">' . __( 'Checkout' ) . '</a>';
endif;