Make WordPress Core


Ignore:
Timestamp:
02/07/2020 05:11:45 AM (4 years ago)
Author:
azaozz
Message:

Media: Add link to the original image in the image properties if it was scaled or rotated after uploading.

Fixes #49290.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/media.php

    r47198 r47202  
    33923392        <?php
    33933393    }
     3394
     3395    if ( ! empty( $meta['original_image'] ) ) {
     3396        ?>
     3397        <div class="misc-pub-section misc-pub-original-image">
     3398            <?php _e( 'Original image:' ); ?>
     3399            <a href="<?php echo esc_url( wp_get_original_image_url( $attachment_id ) ); ?>">
     3400                <?php echo esc_html( wp_basename( wp_get_original_image_path( $attachment_id ) ) ); ?>
     3401            </a>
     3402        </div>
     3403        <?php
     3404    }
    33943405}
    33953406
Note: See TracChangeset for help on using the changeset viewer.