[wp-trac] [WordPress Trac] #50061: Image_meta original_image as valid image_size

WordPress Trac noreply at wordpress.org
Sat May 2 23:31:59 UTC 2020


#50061: Image_meta original_image as valid image_size
-------------------------+-----------------------------
 Reporter:  tomcent      |      Owner:  (none)
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  Media        |    Version:  5.3
 Severity:  normal       |   Keywords:  dev-feedback
  Focuses:               |
-------------------------+-----------------------------
 Since the introduction of the "Big Image Threshold" in Version 5.3 it is
 no longer possible to get the width and height of the original image. The
 name of the original file is stored as string in the image metadata
 (tested with wp_get_attachment_metadata) and functions
 {{{
 wp_get_original_image_path
 }}}
 and
 {{{
 wp_get_original_image_url
 }}}
 will only provide the path and url of the original image.

 It would be more developer friendly to implement it as a valid image size
 in the "sizes" array with name "original" or similar. This way functions
 like wp_get_attachment_image_src could be used to get extended original
 image information, without breaking existing configurations.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/50061>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list