woocommerce_single_product_flexslider_enabled хук-фильтрWC 3.3.2

Get HTML for a gallery image.

Hooks: woocommerce_gallery_thumbnail_size, woocommerce_gallery_image_size and woocommerce_gallery_full_size accept name based image sizes, or an array of width/height values.

Использование

add_filter( 'woocommerce_single_product_flexslider_enabled', 'wp_kama_woocommerce_single_product_flexslider_enabled_filter' );

/**
 * Function for `woocommerce_single_product_flexslider_enabled` filter-hook.
 * 
 * @param int $attachment_id Attachment ID.
 *
 * @return int
 */
function wp_kama_woocommerce_single_product_flexslider_enabled_filter( $attachment_id ){

	// filter...
	return $attachment_id;
}
$attachment_id(int)
Attachment ID.

Список изменений

С версии 3.3.2 Введена.

Где вызывается хук

wc_get_gallery_image_html()
woocommerce_single_product_flexslider_enabled
WC_Frontend_Scripts::get_script_data()
woocommerce_single_product_flexslider_enabled
woocommerce/includes/wc-template-functions.php 1574
$flexslider        = (bool) apply_filters( 'woocommerce_single_product_flexslider_enabled', get_theme_support( 'wc-product-gallery-slider' ) );
woocommerce/includes/class-wc-frontend-scripts.php 531
'flexslider_enabled'        => apply_filters( 'woocommerce_single_product_flexslider_enabled', get_theme_support( 'wc-product-gallery-slider' ) ),

Где используется хук в WooCommerce

Использование не найдено.