From 36e8aa39df5cefa79b311afa86f05a072bf3c139 Mon Sep 17 00:00:00 2001 From: Matt Mullenweg Date: Fri, 1 Dec 2006 03:30:26 +0000 Subject: [PATCH] Adding a hook for comments, fixes #3084 git-svn-id: https://develop.svn.wordpress.org/trunk@4568 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/comment-template.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/wp-includes/comment-template.php b/wp-includes/comment-template.php index 3fee66a206..6f53558730 100644 --- a/wp-includes/comment-template.php +++ b/wp-includes/comment-template.php @@ -290,6 +290,8 @@ function comments_template( $file = '/comments.php' ) { $comments = $wpdb->get_results("SELECT * FROM $wpdb->comments WHERE comment_post_ID = '$post->ID' AND ( comment_approved = '1' OR ( comment_author = '$author_db' AND comment_author_email = '$email_db' AND comment_approved = '0' ) ) ORDER BY comment_date"); } + $comments = apply_filters( 'comments_array', $comments, $post->ID ); + define('COMMENTS_TEMPLATE', true); $include = apply_filters('comments_template', TEMPLATEPATH . $file ); if ( file_exists( $include ) )