تابع ووکامرسی wc_get_rounding_precision دریافت میزان دقت روند کردن مقادیر

تابع ووکامرسی wc_get_rounding_precision – دریافت میزان دقت روند کردن مقادیر
Syntax – سینتکس
(int) wc_get_rounding_precision();
Usage – نحوه استفاده
if ( !function_exists( 'wc_get_rounding_precision' ) ) {
require_once ABSPATH . PLUGINDIR . 'woocommerce/includes/wc-core-functions.php';
}
// NOTICE! Understand what this does before running.
$result = wc_get_rounding_precision();
Defined – محل تعریف
/includes/wc-core-functions.php
function wc_get_rounding_precision() {
$precision = wc_get_price_decimals() + 2;
if ( absint( WC_ROUNDING_PRECISION ) > $precision ) {
$precision = absint( WC_ROUNDING_PRECISION );
}
return $precision;
}
versions – نسخه ها
از نسخه : 2.6.3
نسخه فعلی : 3.0.6
دیگر نسخه ها : 3.0.6 , 3.0.5 , 3.0.4 , 3.0.3 , 3.0.2
ارسال نظر