Learn more  » Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Bower components Debian packages RPM packages NuGet packages

jsarnowski / jsarnowski/jet-blocks   php

Repository URL to install this package:

Version: 1.2.8 

/ jet-blocks-cart / global / cart-totals.php

<?php
/**
 * Cart totals template
 */

$elementor    = Elementor\Plugin::instance();
$is_edit_mode = $elementor->editor->is_edit_mode();

if ( ( $is_edit_mode && ! wp_doing_ajax() ) || null === WC()->cart ) {
	$totals = '';
} else {
	$totals = wp_kses_data( WC()->cart->get_cart_subtotal() );
}

?>
<span class="jet-blocks-cart__total-val"><?php
	echo $totals;
?></span>