WC_Product::get_rating_countspublicWC 1.0

Get rating count.

Method of the class: WC_Product{}

No Hooks.

Returns

Array. of counts

Usage

$WC_Product = new WC_Product();
$WC_Product->get_rating_counts( $context );
$context(string)
What the value is for. Valid values are view and edit.
Default: 'view'

WC_Product::get_rating_counts() code WC 10.3.6

public function get_rating_counts( $context = 'view' ) {
	return $this->get_prop( 'rating_counts', $context );
}