WordPress.org

Make WordPress Core

Ticket #49779: post-template.php.patch

File post-template.php.patch, 565 bytes (added by pikamander2, 20 months ago)

Add attachment page image size filter to fix #49779

  • post-template.php

     
    16741674        } else {
    16751675                $p = '<p class="attachment">';
    16761676                // Show the medium sized image representation of the attachment if available, and link to the raw file.
    1677                 $p .= wp_get_attachment_link( 0, 'medium', false );
     1677                $attachment_size = apply_filters( 'prepend_attachment_size', 'medium' );
     1678                $p .= wp_get_attachment_link( 0, $attachment_size, false );
    16781679                $p .= '</p>';
    16791680        }
    16801681