WordPress.org

Make WordPress Core

Opened 6 months ago

#50061 new enhancement

Image_meta original_image as valid image_size

Reported by: tomcent Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 5.3
Component: Media Keywords: dev-feedback
Focuses: Cc:

Description

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.

Change History (0)

Note: See TracTickets for help on using tickets.