From 3dc7b154691de132c707f4b7f1d8563a03445c3c Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Sun, 24 Feb 2008 21:38:44 +0000 Subject: [PATCH] Date display fixes for manage comments. git-svn-id: https://develop.svn.wordpress.org/trunk@7008 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/edit-comments.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/wp-admin/edit-comments.php b/wp-admin/edit-comments.php index c900fecb6c..8f9770c360 100644 --- a/wp-admin/edit-comments.php +++ b/wp-admin/edit-comments.php @@ -189,6 +189,11 @@ if ($comments) { $author_url_display = $author_url; if ( strlen($author_url_display) > 50 ) $author_url_display = substr($author_url_display, 0, 49) . '...'; + $ptime = get_post_time('G', true); + if ( ( abs(time() - $ptime) ) < 86400 ) + $ptime = sprintf( __('%s ago'), human_time_diff( $ptime ) ); + else + $ptime = mysql2date(__('Y/m/d \a\t g:i A'), $post->post_date); ?> comment_post_ID) ) { ?> @@ -203,9 +208,9 @@ if ($comments) {

-

+

- + comment_post_ID) ) { echo "" . __('Edit') . " | ";