[wp-trac] [WordPress Trac] #20205: move image_downsize filter to beginning of image_downsize() function
WordPress Trac
wp-trac at lists.automattic.com
Fri Mar 9 02:32:50 UTC 2012
#20205: move image_downsize filter to beginning of image_downsize() function
----------------------------+------------------------------
Reporter: helgatheviking | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Media | Version: 3.4
Severity: normal | Resolution:
Keywords: |
----------------------------+------------------------------
Comment (by helgatheviking):
actually i think the function is choking (in terms of being able to do
what i am trying to do)
on the next line in wp_get_attachment_src()
{{{
if ( $icon && $src = wp_mime_type_icon($attachment_id) ) {
$icon_dir = apply_filters( 'icon_dir', ABSPATH . WPINC .
'/images/crystal' );
$src_file = $icon_dir . '/' . wp_basename($src);
@list($width, $height) = getimagesize($src_file);
}
if ( $src && $width && $height )
return array( $src, $width, $height );
return false;
}}}
b/c of what i mentioned above, the path info is wrong, which leads to not
getting the $height and $width, which ends in the function returning
false.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/20205#comment:6>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list