summaryrefslogtreecommitdiffstats
path: root/wp-includes/comment-template.php
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-05-21 18:37:58 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-05-21 18:37:58 +0000
commit89fe0ff804e7c6497ebacc8b341ac89974f6f255 (patch)
tree3fce310b29c685008fdbb75c5ab531bc3a6ae12a /wp-includes/comment-template.php
parenta139071806ba941346a109fbefb2d5f22bae1cc4 (diff)
downloadwordpress-mu-89fe0ff804e7c6497ebacc8b341ac89974f6f255.tar.gz
wordpress-mu-89fe0ff804e7c6497ebacc8b341ac89974f6f255.tar.xz
wordpress-mu-89fe0ff804e7c6497ebacc8b341ac89974f6f255.zip
WP Merge to rev 5499, this is a big one! Test it before you put it live!
Test only, not for production use yet git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@972 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-includes/comment-template.php')
-rw-r--r--wp-includes/comment-template.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/wp-includes/comment-template.php b/wp-includes/comment-template.php
index 0c16240..ed41bb6 100644
--- a/wp-includes/comment-template.php
+++ b/wp-includes/comment-template.php
@@ -228,7 +228,7 @@ function get_trackback_url() {
if ( '' != get_option('permalink_structure') )
$tb_url = trailingslashit(get_permalink()) . user_trailingslashit('trackback', 'single_trackback');
- return $tb_url;
+ return apply_filters('trackback_url', $tb_url);
}
function trackback_url( $display = true ) {
if ( $display)
@@ -288,7 +288,9 @@ function comments_template( $file = '/comments.php' ) {
extract($commenter);
// TODO: Use API instead of SELECTs.
- if ( empty($comment_author) ) {
+ if ( $user_ID) {
+ $comments = $wpdb->get_results("SELECT * FROM $wpdb->comments WHERE comment_post_ID = '$post->ID' AND (comment_approved = '1' OR ( user_id = '$user_ID' AND comment_approved = '0' ) ) ORDER BY comment_date");
+ } else if ( empty($comment_author) ) {
$comments = $wpdb->get_results("SELECT * FROM $wpdb->comments WHERE comment_post_ID = '$post->ID' AND comment_approved = '1' ORDER BY comment_date");
} else {
$author_db = $wpdb->escape($comment_author);
@@ -331,7 +333,7 @@ function comments_popup_link($zero='No Comments', $one='1 Comment', $more='% Com
$number = get_comments_number($id);
if ( 0 == $number && 'closed' == $post->comment_status && 'closed' == $post->ping_status ) {
- echo $none;
+ echo '<span' . ((!empty($CSSclass)) ? ' class="' . $CSSclass . '"' : '') . '>' . $none . '</span>';
return;
}