From 5fb288d031ea8490085a9e9bb650d32e20cce03b Mon Sep 17 00:00:00 2001 From: matt Date: Fri, 25 Dec 2009 02:46:40 +0000 Subject: [PATCH] Change to comments UI to show when a comment is replying to another, and link to the parent comment, so you can understand the context of a given comment when moderating from the dashboard. Long term, I feel like front-end moderation could be really handy if we can make it as AJAXy. git-svn-id: http://svn.automattic.com/wordpress/trunk@12540 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/template.php | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php index 4229726766..f0a48d6c86 100644 --- a/wp-admin/includes/template.php +++ b/wp-admin/includes/template.php @@ -2146,7 +2146,15 @@ function _wp_comment_row( $comment_id, $mode, $comment_status, $checkbox = true, case 'comment': echo ""; echo '
'; - printf(__('Submitted on %2$s at %3$s'), $comment_url, get_comment_date(__('Y/m/d')), get_comment_date(__('g:ia'))); + printf( __( '%2$s at %3$s' ), $comment_url, get_comment_date( __('Y/m/d') ), get_comment_date( __( 'g:ia' ) ) ); + + if ( $comment->comment_parent ) { + $parent = get_comment( $comment->comment_parent ); + $parent_link = esc_url( get_comment_link( $comment->comment_parent ) ); + $name = apply_filters( 'get_comment_author', $parent->comment_author ); // there's no API function for this + printf( __( ' | In reply to %2$s.' ), $parent_link, $name ); + } + echo '
'; comment_text(); if ( $user_can ) { ?> @@ -2560,7 +2568,7 @@ function meta_form() { ?> - + @@ -3231,7 +3239,7 @@ function find_posts_div($found_action = '') { -
+
@@ -3241,7 +3249,7 @@ function find_posts_div($found_action = '') {
- +