[wp-trac] [WordPress Trac] #15311: dynamic image resize (on the fly) using already available functions

WordPress Trac noreply at wordpress.org
Sat Jan 10 03:34:25 UTC 2015


#15311: dynamic image resize (on the fly) using already available functions
------------------------------------+-----------------------------
 Reporter:  vteixeira               |       Owner:
     Type:  enhancement             |      Status:  new
 Priority:  normal                  |   Milestone:  Future Release
Component:  Media                   |     Version:  3.1
 Severity:  normal                  |  Resolution:
 Keywords:  dev-feedback has-patch  |     Focuses:
------------------------------------+-----------------------------

Comment (by ericlewis):

 In attachment:15311.5.diff,

 * move this logic in `image_get_intermediate_size()`, as drrobotnick had
 in his patch. This is the canonical function for attempting to get a file
 for an image size, which other functions like `image_downsize()` proxy to.
 * add a unit test.
 * give preference of cutting from the large size if it exists and is big
 enough, otherwise fallback to the original.

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


More information about the wp-trac mailing list