~canonical-sysadmins/wordpress/4.8.3

« back to all changes in this revision

Viewing changes to wp-includes/post-thumbnail-template.php

  • Committer: Ryan Finnie
  • Date: 2015-08-31 16:09:47 UTC
  • mfrom: (1.1.9 upstream)
  • Revision ID: ryan.finnie@canonical.com-20150831160947-1h6rfxby9z1ec62u
Merge WP4.3 from upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
 *
27
27
 * @since 2.9.0
28
28
 *
29
 
 * @param int $post_id Optional. Post ID.
30
 
 * @return int
 
29
 * @param int|null $post_id Optional. Post ID.
 
30
 * @return mixed
31
31
 */
32
32
function get_post_thumbnail_id( $post_id = null ) {
33
33
        $post_id = ( null === $post_id ) ? get_the_ID() : $post_id;
61
61
 *
62
62
 * @since 3.2.0
63
63
 *
64
 
 * @param object $wp_query Optional. A WP_Query instance. Defaults to the $wp_query global.
 
64
 * @global WP_Query $wp_query
 
65
 *
 
66
 * @param WP_Query $wp_query Optional. A WP_Query instance. Defaults to the $wp_query global.
65
67
 */
66
68
function update_post_thumbnail_cache( $wp_query = null ) {
67
69
        if ( ! $wp_query )
99
101
 * @param string|array $size Optional. Registered image size to use, or flat array of height
100
102
 *                           and width values. Default 'post-thumbnail'.
101
103
 * @param string|array $attr Optional. Query string or array of attributes. Default empty.
 
104
 * @return string
102
105
 */
103
106
function get_the_post_thumbnail( $post_id = null, $size = 'post-thumbnail', $attr = '' ) {
104
107
        $post_id = ( null === $post_id ) ? get_the_ID() : $post_id;