تابع ووکامرسی wc_get_coupon_types دریافت تمامی نوع های کوپن

تابع ووکامرسی wc_get_coupon_types دریافت تمامی نوع های کوپن

تابع ووکامرسی wc_get_coupon_types – دریافت تمامی نوع های کوپن

Syntax – سینتکس

(array) wc_get_coupon_types(); 

Usage – نحوه استفاده

if ( !function_exists( 'wc_get_coupon_types' ) ) { 
    require_once ABSPATH . PLUGINDIR . 'woocommerce/includes/wc-coupon-functions.php'; 
} 
 
  
// NOTICE! Understand what this does before running. 
$result = wc_get_coupon_types(); 
    

Defined – محل تعریف

/includes/wc-coupon-functions.php

function wc_get_coupon_types() { 
    return (array) apply_filters( 'woocommerce_coupon_discount_types', array( 
        'percent' => __( 'Percentage discount', woocommerce ),  
        'fixed_cart' => __( 'Fixed cart discount', woocommerce ),  
        'fixed_product' => __( 'Fixed product discount', woocommerce ),  
 ) ); 
} 

versions – نسخه ها

از نسخه : 3.0.2

نسخه فعلی : 3.0.6

دیگر نسخه ها : 3.0.6 , 3.0.5 , 3.0.4 , 3.0.3 , 3.0.2

ارسال نظر

جهت استفاده از کد حتما از تگ pre استفاده نمایید .

contact us