woocommerce_add_message хук-фильтрWC 2.1

Print a single notice immediately.

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

add_filter( 'woocommerce_add_message', 'wp_kama_woocommerce_add_message_filter' );

/**
 * Function for `woocommerce_add_message` filter-hook.
 * 
 * @param string $message The text to display in the notice.
 *
 * @return string
 */
function wp_kama_woocommerce_add_message_filter( $message ){

	// filter...
	return $message;
}
$message(строка)
The text to display in the notice.

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

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

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

wc_print_notice()
woocommerce_add_message
wc_add_notice()
woocommerce_add_message
woocommerce/includes/wc-notice-functions.php 196
$message = apply_filters( 'woocommerce_add_message', $message );
woocommerce/includes/wc-notice-functions.php 86
$message = apply_filters( 'woocommerce_add_message', $message );

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

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