comment_status_links хук-фильтрWP 2.5.0

Filters the comment status links.

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

add_filter( 'comment_status_links', 'wp_kama_comment_status_links_filter' );

/**
 * Function for `comment_status_links` filter-hook.
 * 
 * @param string[] $status_links An associative array of fully-formed comment status links. Includes 'All', 'Mine', 'Pending', 'Approved', 'Spam', and 'Trash'.
 *
 * @return string[]
 */
function wp_kama_comment_status_links_filter( $status_links ){

	// filter...
	return $status_links;
}
$status_links(string[])
An associative array of fully-formed comment status links. Includes 'All', 'Mine', 'Pending', 'Approved', 'Spam', and 'Trash'.

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

С версии 2.5.0 Введена.
С версии 5.1.0 The 'Mine' link was added.

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

WP_Comments_List_Table::get_views()
comment_status_links
wp-admin/includes/class-wp-comments-list-table.php 349
return apply_filters( 'comment_status_links', $this->get_views_links( $status_links ) );

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

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