woocommerce_product_variation_title_include_attributes

woocommerce_product_variation_title_include_attributes

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: woocommerce.8.7.0

apply_filters('woocommerce_product_variation_title_include_attributes') is found 1 times:

  • /includes/data-stores/class-wc-product-variation-data-store-cpt.php line 308
    				}
    			}
    		}
    
    		$should_include_attributes = apply_filters( 'woocommerce_product_variation_title_include_attributes', $should_include_attributes, $product );
    		$separator                 = apply_filters( 'woocommerce_product_variation_title_attributes_separator', ' - ', $product );
    		$title_base                = get_post_field( 'post_title', $product->get_parent_id() );
    		$title_suffix              = $should_include_attributes ? wc_get_formatted_variation( $product, true, false ) : '';
    
    		return apply_filters( 'woocommerce_product_variation_title', $title_suffix ? $title_base . $separator . $title_suffix : $title_base, $product, $title_base, $title_suffix );
    	}