diff --git a/wp-admin/admin-functions.php b/wp-admin/admin-functions.php
index a2f8f9748f..26fdd037fb 100644
--- a/wp-admin/admin-functions.php
+++ b/wp-admin/admin-functions.php
@@ -1,5 +1,15 @@
35)
+ $short_url = substr($short_url, 0, 32).'...';
+ return $short_url;
+}
+
function selected($selected, $current) {
if ($selected == $current) echo ' selected="selected"';
}
diff --git a/wp-admin/edit-comments.php b/wp-admin/edit-comments.php
index 755a57a45b..74e0e452fa 100644
--- a/wp-admin/edit-comments.php
+++ b/wp-admin/edit-comments.php
@@ -2,19 +2,37 @@
$title = 'Edit Comments';
$parent_file = 'edit.php';
require_once('admin-header.php');
+if (empty($_GET['mode'])) $mode = 'view';
+else $mode = $_GET['mode'];
?>
-
+
View Mode | Mass Edit Mode
@@ -27,10 +45,11 @@ if ($s) {
comment_author_url LIKE ('%$s%') OR
comment_author_IP LIKE ('%$s%') OR
comment_content LIKE ('%$s%')
- ORDER BY comment_date");
+ ORDER BY comment_date DESC");
} else {
- $comments = $wpdb->get_results("SELECT * FROM $tablecomments ORDER BY comment_date $commentorder LIMIT 20");
+ $comments = $wpdb->get_results("SELECT * FROM $tablecomments ORDER BY comment_date DESC LIMIT 20");
}
+if ('view' == $mode) {
if ($comments) {
echo '
';
foreach ($comments as $comment) {
@@ -58,6 +77,48 @@ if ($s) {
';
+ } else {
+
+ ?>
+
+ No results found.
+
+
+
+ Invert Checkbox Selection
+
+
+
@@ -67,7 +128,7 @@ if ($s) {
diff --git a/wp-admin/moderation.php b/wp-admin/moderation.php
index 7892530615..6d756315c5 100644
--- a/wp-admin/moderation.php
+++ b/wp-admin/moderation.php
@@ -96,9 +96,9 @@ default:
}
?>
comment_ID."
}
?>
-
+
' . $author . '';
}
@@ -153,7 +157,7 @@ function comment_author_email_link($linktext='', $before='', $after='') {
global $comment;
$email = apply_filters('comment_email', $comment->comment_author_email);
if ((!empty($email)) && ($email != '@')) {
- $display = ($linktext != '') ? $linktext : antispambot(stripslashes($email));
+ $display = ($linktext != '') ? $linktext : stripslashes($email);
echo $before;
echo "$display ";
echo $after;
@@ -184,6 +188,27 @@ function comment_text() {
echo apply_filters('comment_text', $comment_text);
}
+function comment_excerpt() {
+ global $comment;
+ $comment_text = str_replace(' ', '', $comment->comment_content);
+ $comment_text = str_replace(' ', '', $comment_text);
+ $comment_text = strip_tags($comment_text);
+ $blah = explode(' ', $comment_text);
+ if (count($blah) > 20) {
+ $k = 20;
+ $use_dotdotdot = 1;
+ } else {
+ $k = count($blah);
+ $use_dotdotdot = 0;
+ }
+ $excerpt = '';
+ for ($i=0; $i<$k; $i++) {
+ $excerpt .= $blah[$i] . ' ';
+ }
+ $excerpt .= ($use_dotdotdot) ? '...' : '';
+ echo apply_filters('comment_excerpt', $excerpt);
+}
+
function comment_date($d='') {
global $comment;
if ('' == $d) {