wc_order_attribution_allow_multiple_elements filter-hookWC 10.5.0

Filter to allow sites to opt back into single-output behavior.

Usage

add_filter( 'wc_order_attribution_allow_multiple_elements', 'wp_kama_wc_order_attribution_allow_multiple_elements_filter' );

/**
 * Function for `wc_order_attribution_allow_multiple_elements` filter-hook.
 * 
 * @param bool $allow_multiple_elements True to allow multiple elements (new behavior), false for single element (old behavior).
 *
 * @return bool
 */
function wp_kama_wc_order_attribution_allow_multiple_elements_filter( $allow_multiple_elements ){

	// filter...
	return $allow_multiple_elements;
}
$allow_multiple_elements(true|false)
True to allow multiple elements (new behavior), false for single element (old behavior).

Changelog

Since 10.5.0 Introduced.

Where the hook is called

OrderAttributionController::stamp_html_element()
wc_order_attribution_allow_multiple_elements
woocommerce/src/Internal/Orders/OrderAttributionController.php 430
$allow_multiple = apply_filters( 'wc_order_attribution_allow_multiple_elements', true );

Where the hook is used in WooCommerce

Usage not found.