WordPress at Your Fingertips
function is not described

WC_Tax::get_rates() public WC 1.0

Get's an array of matching rates for a tax class.

{} It's a method of the class: WC_Tax{}

No Hooks.




$result = WC_Tax::get_rates( $tax_class, $customer );
Tax class to get rates for.
Default: ''
Override the customer object to get their location.
Default: null

Code of WC_Tax::get_rates() WC 5.9.0

public static function get_rates( $tax_class = '', $customer = null ) {
	$tax_class = sanitize_title( $tax_class );
	$location  = self::get_tax_location( $tax_class, $customer );
	return self::get_rates_from_location( $tax_class, $location, $customer );