public static function get_tax_for_display($tax_class) { $return = false; if (fflcommerce_cart::get_tax_amount($tax_class, false) > 0 && fflcommerce_cart::get_tax_rate($tax_class) > 0 || fflcommerce_cart::get_tax_rate($tax_class) !== false) { $return = self::$tax->get_tax_class_for_display($tax_class) . ' (' . (double) fflcommerce_cart::get_tax_rate($tax_class) . '%) '; // only show estimated tag when customer is on the cart page and no shipping calculator is enabled to be able to change country if (!fflcommerce_shipping::show_shipping_calculator() && is_cart()) { $return .= '<small>' . sprintf(__('estimated for: %s', 'fflcommerece'), fflcommerce_countries::get_country(fflcommerce_tax::get_customer_country())) . '</small>'; } } return $return; }