[wp-trac] [WordPress Trac] #18947: get_intermediate_image_sizes() should also contain width/height/crop values as sub array
WordPress Trac
noreply at wordpress.org
Mon Jun 2 21:52:16 UTC 2014
#18947: get_intermediate_image_sizes() should also contain width/height/crop values
as sub array
-----------------------------------+-----------------------
Reporter: F J Kaiser | Owner:
Type: enhancement | Status: assigned
Priority: normal | Milestone: 4.0
Component: Media | Version: 3.2.1
Severity: normal | Resolution:
Keywords: has-patch 2nd-opinion | Focuses:
-----------------------------------+-----------------------
Comment (by F J Kaiser):
Replying to [comment:13 ericlewis]:
> Custom image sizes width/height info is not stored in the database,
there should be a fallback to go to the `global
$_wp_addtional_image_sizes` array to fetch this data.
The following options are set during installation
[https://github.com/WordPress/WordPress/blob/master/wp-
admin/includes/schema.php#L443 since 2.5]:
{{{
'thumbnail_size_w' => 150,
'thumbnail_size_h' => 150,
'thumbnail_crop' => 1,
'medium_size_w' => 300,
'medium_size_h' => 300,
}}}
and [https://github.com/WordPress/WordPress/blob/master/wp-
admin/includes/schema.php#L453 since 2.7] we got
{{{
'large_size_w' => 1024,
'large_size_h' => 1024,
}}}
Crop really isn't there as default. Imo and as this will be a new
function, we should leave it being not set, so whoever writes a patch core
later on can implement it independently and without thinking about
anything relying on it. Else we would make false assumptions or define new
settings just for the sake of an array key.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/18947#comment:15>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list