[wp-trac] Re: [WordPress Trac] #8480: apply_filters('post_gallery',
'', $attr) should be apply_filters('post_gallery', $attr);
WordPress Trac
wp-trac at lists.automattic.com
Fri Dec 5 01:28:09 GMT 2008
#8480: apply_filters('post_gallery', '', $attr) should be
apply_filters('post_gallery', $attr);
-----------------------------------------------+----------------------------
Reporter: chionsas.org | Owner:
Type: defect | Status: closed
Priority: normal | Milestone:
Component: Gallery | Version: 2.7
Severity: normal | Resolution: invalid
Keywords: gallery, shortcode, apply_filters |
-----------------------------------------------+----------------------------
Comment (by DD32):
> but I still don't understand the need for the first parameter (since
it's always an empty string).. :?
Think of it like this, The empty string IS the gallery content.
If $attr was passed in as the first param, then it would be filtering the
$attr array, Which could give the wrong impression. $attr is mearly extra
information, its not whats being filtered.
--
Ticket URL: <http://trac.wordpress.org/ticket/8480#comment:4>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list