WordPress Hooks Explorer

Listing all hooks extracted WordPress Core


Details about has_post_thumbnail

Back to home

Files

Filename Hook Type Line Number PHP Doc
wp-includes/post-thumbnail-template.php apply_filters 38 /**
* Filters whether a post has a post thumbnail.
*
* @since 5.1.0
*
* @param bool $has_thumbnail true if the post has a post thumbnail, otherwise false.
* @param int|WP_Post|null $post Post ID or WP_Post object. Default is global `$post`.
* @param int|false $thumbnail_id Post thumbnail ID or false if the post does not exist.
*/

Hook Parameters

Parameter Type Name Description
bool $has_thumbnail true if the post has a post thumbnail, otherwise false.
int|WP_Post|null $post Post ID or WP_Post object. Default is global `$post`.
int|false $thumbnail_id Post thumbnail ID or false if the post does not exist.