[wp-trac] [WordPress Trac] #48302: Big Image: Provide function to get original file URL

WordPress Trac noreply at wordpress.org
Tue Oct 15 17:33:12 UTC 2019


#48302: Big Image: Provide function to get original file URL
--------------------------+---------------------
 Reporter:  kraftbj       |       Owner:  (none)
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  5.3
Component:  Media         |     Version:  trunk
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:
--------------------------+---------------------

Comment (by azaozz):

 > After r46076, for big images, the original file is saved as attachment
 metadata outside of the sizes array. This can make it a bit of an extra
 work to get the original URL for an image.

 This is intentional. The logic here is that the original file is stored
 but not used as the "largest" size anywhere. Same as if the user has
 scaled down the image before uploading it.

 In these cases the original is used only to make new image sub-sizes as
 they will be of better quality.

 If there are compelling user cases where the original, usually not
 suitable for web use, image is needed on a regular basis, I don't mind
 adding a core function to facilitate it. But if there isn't such case, why
 would that function be needed?

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/48302#comment:7>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list