[wp-trac] [WordPress Trac] #6691: 'image_send_to_editor' hook has a missing parameter

WordPress Trac wp-trac at lists.automattic.com
Sat Apr 12 06:45:04 GMT 2008


#6691: 'image_send_to_editor' hook has a missing parameter
----------------------+-----------------------------------------------------
 Reporter:  duncanmc  |       Owner:  anonymous
     Type:  defect    |      Status:  new      
 Priority:  normal    |   Milestone:  2.5.1    
Component:  General   |     Version:  2.5      
 Severity:  normal    |    Keywords:           
----------------------+-----------------------------------------------------
 I am implementing a plugin using a filter that hooks
 'image_send_to_editor'. This filter is called in functions
 get_image_tag($id, $alt, $title, $align, $size='medium') and
 get_image_send_to_editor($id, $alt, $title, $align, $url='', $rel = false,
 $size='medium') . The hook accepts parameters $html, $id, $alt, $title,
 $align, $url as it is called in these two functions by the command
 apply_filters( 'image_send_to_editor', $html, $id, $alt, $title, $align,
 $url ). There is a missing parameter here. Both these functions get and
 use $size parameter, but the filter does not get it. $size parameter is
 necessary for the filter. Otherwise it can not detect the image size
 selected in the media uploader. Could you please update the hook
 'image_send_to_editor' so that it also accepts $size parameter?

-- 
Ticket URL: <http://trac.wordpress.org/ticket/6691>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list