Summery Summery
Returns the post thumbnail caption.
Syntax Syntax
Parameters Parameters
- $post
-
(Optional) Post ID or WP_Post object. Default is global
$post.Default value: null
Return Return
(string) Post thumbnail caption.
Source Source
File: wp-includes/post-thumbnail-template.php
if ( $url ) {
echo esc_url( $url );
}
}
/**
* Returns the post thumbnail caption.
*
* @since 4.6.0
*
* @param int|WP_Post $post Optional. Post ID or WP_Post object. Default is global `$post`.
* @return string Post thumbnail caption.
*/
Advertisement
Changelog Changelog
| Version | Description |
|---|---|
| 4.6.0 | Introduced. |