[wp-trac] [WordPress Trac] #11167: Pass $size and $attr to post_image_html filter
WordPress Trac
wp-trac at lists.automattic.com
Wed Nov 18 10:25:57 UTC 2009
#11167: Pass $size and $attr to post_image_html filter
-------------------------+--------------------------------------------------
Reporter: waltervos | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: 2.9
Component: Media | Version: 2.9
Severity: normal | Keywords: has-patch needs-testing the_post_image filter
-------------------------+--------------------------------------------------
It seems strange to me that get_the_post_image accepts $post_id, $size and
$attr but when the filter post_image_html is applied, these parameters are
not passed to it. This way, when $html is empty (when an image wasn't
found) a plugin author only has $post_id to work with it. If you wanted to
make a plugin that will use a default image where no post_image was found,
you couldn't. A patch is attached to this ticket to illustrate what I
mean.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/11167>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list