Dmitry
Forum Replies Created
Viewing 4 replies - 1 through 4 (of 4 total)
-
Forum: Plugins
In reply to: [WooCommerce] Cleaning the mini cart after paymentIt may be useful to anyone but there was a problem with wc-cart-fragments and SessionStorage:
wc-cart-fragments' => array( 'src' => self::get_asset_url( 'assets/js/frontend/cart-fragments' . $suffix . '.js' ), 'deps' => array( 'jquery', 'js-cookie' ), 'version' => WC_VERSION, )you need to disable the connection of this script:
add_action( 'wp_print_scripts', 'de_script', 100 ); function de_script() { wp_dequeue_script( 'wc-cart-fragments' ); return true; }Forum: Plugins
In reply to: [WooCommerce] Cleaning the mini cart after paymentDisabled caching on the website and the server, cleaned the cache, the problem remains ((( actually in the basket or what not, does not work after the payment:
function wc_mini_cart_refresh( $fragments ) { global $woocommerce; ob_start(); ?> <span class='woo_mini-count flaticon-shopcart-icon'><?php echo ((WC()->cart->cart_contents_count > 0) ? '<span>' . esc_html( WC()->cart->cart_contents_count ) .'</span>' : '') ?></span> <?php $fragments['.woo_mini-count'] = ob_get_clean(); ob_start(); woocommerce_mini_cart(); $fragments['div.woo_mini_cart'] = ob_get_clean(); return $fragments; }Forum: Plugins
In reply to: [WooCommerce] Cleaning the mini cart after paymentPrompt the solution of a problem
I welcome, to be honest I did not quite understand what kind of file you need to create and what should be in this file.
Viewing 4 replies - 1 through 4 (of 4 total)