WC_Cart::get_total_discount() public WC 1.0
Gets the total discount amount.
{} Это метод класса: WC_Cart{}
Хуки из метода
Возвращает
Разное. formatted price or false if there are none
Использование
$WC_Cart = new WC_Cart(); $WC_Cart->get_total_discount();
Код WC_Cart::get_total_discount() WC Cart::get total discount WC 5.0.0
public function get_total_discount() {
return apply_filters( 'woocommerce_cart_total_discount', $this->get_discount_total() ? wc_price( $this->get_discount_total() ) : false, $this );
}