show_recent_comments_widget_style хук-фильтрWP 3.1.0

Filters the Recent Comments default widget styles.

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

add_filter( 'show_recent_comments_widget_style', 'wp_kama_show_recent_comments_widget_style_filter', 10, 2 );

/**
 * Function for `show_recent_comments_widget_style` filter-hook.
 * 
 * @param bool   $active  Whether the widget is active.
 * @param string $id_base The widget ID.
 *
 * @return bool
 */
function wp_kama_show_recent_comments_widget_style_filter( $active, $id_base ){

	// filter...
	return $active;
}
$active(true|false)
Whether the widget is active.
По умолчанию: true
$id_base(строка)
The widget ID.

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

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

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

WP_Widget_Recent_Comments::recent_comments_style()
show_recent_comments_widget_style
wp-includes/widgets/class-wp-widget-recent-comments.php 54
|| ! apply_filters( 'show_recent_comments_widget_style', true, $this->id_base ) ) {

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

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