admin_post_thumbnail_html filter-hookWP 2.9.0

Filters the admin post thumbnail HTML markup to return.

Usage

add_filter( 'admin_post_thumbnail_html', 'wp_kama_admin_post_thumbnail_html_filter', 10, 3 );

/**
 * Function for `admin_post_thumbnail_html` filter-hook.
 * 
 * @param string   $content      Admin post thumbnail HTML markup.
 * @param int      $post_id      Post ID.
 * @param int|null $thumbnail_id Thumbnail attachment ID, or null if there isn't one.
 *
 * @return string
 */
function wp_kama_admin_post_thumbnail_html_filter( $content, $post_id, $thumbnail_id ){

	// filter...
	return $content;
}
$content(string)
Admin post thumbnail HTML markup.
$post_id(int)
Post ID.
$thumbnail_id(int|null)
Thumbnail attachment ID, or null if there isn't one.

Changelog

Since 2.9.0 Introduced.
Since 3.5.0 Added the $post_id parameter.
Since 4.6.0 Added the $thumbnail_id parameter.

Where the hook is called

_wp_post_thumbnail_html()
admin_post_thumbnail_html
wp-admin/includes/post.php 1626
return apply_filters( 'admin_post_thumbnail_html', $content, $post->ID, $thumbnail_id );

Where the hook is used in WordPress

Usage not found.