WC_Discounts::get_discounted_price_in_cents( object $item )

Get discounted price of an item to precision (in cents).


Description Description


Parameters Parameters

$item

(Required) Get data for this item.


Top ↑

Return Return

(int)


Top ↑

Source Source

File: includes/class-wc-discounts.php

	public function get_discounted_price_in_cents( $item ) {
		return absint( round( $item->price - $this->get_discount( $item->key, true ) ) );
	}

Top ↑

Changelog Changelog

Changelog
Version Description
3.2.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.