wc_get_tax_class_by_tax_id()WC 2.2

Get tax class by tax id.

No Hooks.

Return

String.

Usage

wc_get_tax_class_by_tax_id( $tax_id );
$tax_id(int) (required)
Tax ID.

Changelog

Since 2.2 Introduced.

wc_get_tax_class_by_tax_id() code WC 9.4.2

function wc_get_tax_class_by_tax_id( $tax_id ) {
	global $wpdb;
	return $wpdb->get_var( $wpdb->prepare( "SELECT tax_rate_class FROM {$wpdb->prefix}woocommerce_tax_rates WHERE tax_rate_id = %d", $tax_id ) );
}