wc_get_product_visibility_term_ids دریافت آیدی ترم نمایش پذیری محصولات

تابع ووکامرسی wc_get_product_visibility_term_ids – دریافت آیدی ترم نمایش پذیری محصولات
Syntax – سینتکس
(int[]) wc_get_product_visibility_term_ids();
Usage – نحوه استفاده
if ( !function_exists( 'wc_get_product_visibility_term_ids' ) ) { require_once ABSPATH . PLUGINDIR . 'woocommerce/includes/wc-term-functions.php'; } // NOTICE! Understand what this does before running. $result = wc_get_product_visibility_term_ids();
Defined – محل تعریف
/includes/wc-term-functions.php
function wc_get_product_visibility_term_ids() { return array_map( 'absint', wp_parse_args( wp_list_pluck( get_terms( array( 'taxonomy' => 'product_visibility', 'hide_empty' => false, ) ), 'term_taxonomy_id', 'name' ), array( 'exclude-from-catalog' => 0, 'exclude-from-search' => 0, 'featured' => 0, 'outofstock' => 0, 'rated-1' => 0, 'rated-2' => 0, 'rated-3' => 0, 'rated-4' => 0, 'rated-5' => 0, ) ) ); }
versions – نسخه ها
از نسخه : 3.0.0
نسخه فعلی : 3.0.6
دیگر نسخه ها : 3.0.6 , 3.0.5 , 3.0.4 , 3.0.3 , 3.0.2
ارسال نظر