[wp-hackers] Filtering by comment_type

scribu scribu at gmail.com
Fri Aug 21 16:30:59 UTC 2009


On Fri, Aug 21, 2009 at 7:11 PM, Mohammad Jangda <batmoo at gmail.com> wrote:

> I found the following filter which I suppose I could use to loop through
> remove any comments with a specific type from the array. But I don't see
> that as being a very elegant solution.
>
> $wp_query->comments = apply_filters( 'comments_array', $comments, $post->ID
> );
>
> Any other suggestions? And does anyone forsee any issues with the way I'm
> doing things?


That seems to be the correct filter. I don't see a better way to do it.


-- 
http://scribu.net


More information about the wp-hackers mailing list