Change the Woocommerce “Add to Cart” total item notification to “Total Product Entry.”
Insert this code into the functions.php function child_theme_enqueue_styles() { // cart page wp_localize_script( ‘global-js’, ‘customMiniCartParams’, array( ‘totalUniqueProducts’ => custom_get_total_unique_products_in_cart(), ) ); } // Modify your PHP function to return the total unique products as a JavaScript variable function custom_get_total_unique_products_in_cart() { $total_unique_products = 0; // Get the cart contents $cart = WC()->cart->get_cart(); // Create an array […]