wc_get_product_tax_class_options دریافت گزینه های کلاس مالیات محصول

تابع ووکامرسی wc_get_product_tax_class_options – دریافت گزینه های کلاس مالیات محصول
Syntax – سینتکس
(array) wc_get_product_tax_class_options();
Usage – نحوه استفاده
if ( !function_exists( 'wc_get_product_tax_class_options' ) ) {
require_once ABSPATH . PLUGINDIR . 'woocommerce/includes/wc-product-functions.php';
}
// NOTICE! Understand what this does before running.
$result = wc_get_product_tax_class_options();
Defined – محل تعریف
/includes/wc-product-functions.php
function wc_get_product_tax_class_options() {
$tax_classes = WC_Tax::get_tax_classes();
$tax_class_options = array();
$tax_class_options[''] = __( 'Standard', woocommerce );
if ( ! empty( $tax_classes ) ) {
foreach ( $tax_classes as $class ) {
$tax_class_options[ sanitize_title( $class ) ] = $class;
}
}
return $tax_class_options;
}
versions – نسخه ها
از نسخه : 3.0.0
نسخه فعلی : 3.0.6
دیگر نسخه ها : 3.0.6 , 3.0.5 , 3.0.4 , 3.0.3 , 3.0.2
ارسال نظر