| [ Root ] [ Search ] [ Index ] |
PHP Cross Reference of WordPress 3.0.1Provided by Yoast |
[Summary view] [Print] [Text view]
1 <?php 2 /** 3 * Edit Comments Administration Panel. 4 * 5 * @package WordPress 6 * @subpackage Administration 7 */ 8 9 /** WordPress Administration Bootstrap */ 10 require_once ('./admin.php'); 11 12 if ( !current_user_can('edit_posts') ) 13 wp_die(__('Cheatin’ uh?')); 14 15 wp_enqueue_script('admin-comments'); 16 enqueue_comment_hotkeys_js(); 17 18 $post_id = isset($_REQUEST['p']) ? (int) $_REQUEST['p'] : 0; 19 20 if ( isset($_REQUEST['doaction']) || isset($_REQUEST['doaction2']) || isset($_REQUEST['delete_all']) || isset($_REQUEST['delete_all2']) ) { 21 check_admin_referer('bulk-comments'); 22 23 if ( (isset($_REQUEST['delete_all']) || isset($_REQUEST['delete_all2'])) && !empty($_REQUEST['pagegen_timestamp']) ) { 24 $comment_status = $wpdb->escape($_REQUEST['comment_status']); 25 $delete_time = $wpdb->escape($_REQUEST['pagegen_timestamp']); 26 $comment_ids = $wpdb->get_col( "SELECT comment_ID FROM $wpdb->comments WHERE comment_approved = '$comment_status' AND '$delete_time' > comment_date_gmt" ); 27 $doaction = 'delete'; 28 } elseif ( ($_REQUEST['action'] != -1 || $_REQUEST['action2'] != -1) && isset($_REQUEST['delete_comments']) ) { 29 $comment_ids = $_REQUEST['delete_comments']; 30 $doaction = ($_REQUEST['action'] != -1) ? $_REQUEST['action'] : $_REQUEST['action2']; 31 } elseif ( $_REQUEST['doaction'] == 'undo' && isset($_REQUEST['ids']) ) { 32 $comment_ids = array_map( 'absint', explode(',', $_REQUEST['ids']) ); 33 $doaction = $_REQUEST['action']; 34 } else { 35 wp_redirect( wp_get_referer() ); 36 } 37 38 $approved = $unapproved = $spammed = $unspammed = $trashed = $untrashed = $deleted = 0; 39 $redirect_to = remove_query_arg( array('trashed', 'untrashed', 'deleted', 'spammed', 'unspammed', 'approved', 'unapproved', 'ids'), wp_get_referer() ); 40 41 foreach ($comment_ids as $comment_id) { // Check the permissions on each 42 $_post_id = (int) $wpdb->get_var( $wpdb->prepare( "SELECT comment_post_ID FROM $wpdb->comments WHERE comment_ID = %d", $comment_id) ); 43 44 if ( !current_user_can('edit_post', $_post_id) ) 45 continue; 46 47 switch( $doaction ) { 48 case 'approve' : 49 wp_set_comment_status($comment_id, 'approve'); 50 $approved++; 51 break; 52 case 'unapprove' : 53 wp_set_comment_status($comment_id, 'hold'); 54 $unapproved++; 55 break; 56 case 'spam' : 57 wp_spam_comment($comment_id); 58 $spammed++; 59 break; 60 case 'unspam' : 61 wp_unspam_comment($comment_id); 62 $unspammed++; 63 break; 64 case 'trash' : 65 wp_trash_comment($comment_id); 66 $trashed++; 67 break; 68 case 'untrash' : 69 wp_untrash_comment($comment_id); 70 $untrashed++; 71 break; 72 case 'delete' : 73 wp_delete_comment($comment_id); 74 $deleted++; 75 break; 76 } 77 } 78 79 if ( $approved ) 80 $redirect_to = add_query_arg( 'approved', $approved, $redirect_to ); 81 if ( $unapproved ) 82 $redirect_to = add_query_arg( 'unapproved', $unapproved, $redirect_to ); 83 if ( $spammed ) 84 $redirect_to = add_query_arg( 'spammed', $spammed, $redirect_to ); 85 if ( $unspammed ) 86 $redirect_to = add_query_arg( 'unspammed', $unspammed, $redirect_to ); 87 if ( $trashed ) 88 $redirect_to = add_query_arg( 'trashed', $trashed, $redirect_to ); 89 if ( $untrashed ) 90 $redirect_to = add_query_arg( 'untrashed', $untrashed, $redirect_to ); 91 if ( $deleted ) 92 $redirect_to = add_query_arg( 'deleted', $deleted, $redirect_to ); 93 if ( $trashed || $spammed ) 94 $redirect_to = add_query_arg( 'ids', join(',', $comment_ids), $redirect_to ); 95 96 wp_redirect( $redirect_to ); 97 exit; 98 } elseif ( ! empty($_GET['_wp_http_referer']) ) { 99 wp_redirect( remove_query_arg( array('_wp_http_referer', '_wpnonce'), stripslashes($_SERVER['REQUEST_URI']) ) ); 100 exit; 101 } 102 103 if ( $post_id ) 104 $title = sprintf(__('Comments on “%s”'), wp_html_excerpt(_draft_or_post_title($post_id), 50)); 105 else 106 $title = __('Comments'); 107 108 add_contextual_help( $current_screen, '<p>' . __('You can manage comments made on your site similar to the way you manage Posts and other content. This screen is customizable in the same ways as other management screens, and you can act on comments using the on-hover action links or the Bulk Actions.') . '</p>' . 109 '<p>' . __('A yellow row means the comment is waiting for you to moderate it.') . '</p>' . 110 '<p>' . __('In the Author column, in addition to the author’s name, email address, and blog URL, the commenter’s IP address is shown. Clicking on this link will show you all the comments made from this IP address.') . '</p>' . 111 '<p>' . __('In the Comment column, above each comment it says “Submitted on,” followed by the date and time the comment was left on your site. Clicking on the date/time link will take you to that comment on your live site.') . '</p>' . 112 '<p>' . __('In the In Response To column, there are three elements. The text is the name of the post that inspired the comment, and links to the post editor for that entry. The “#” permalink symbol below leads to that post on your live site. The small bubble with the number in it shows how many comments that post has received. If the bubble is gray, you have moderated all comments for that post. If it is blue, there are pending comments. Clicking the bubble will filter the comments screen to show only comments on that post.') . '</p>' . 113 '<p>' . __('Many people take advantage of keyboard shortcuts to moderate their comments more quickly. Use the link below to learn more.') . '</p>' . 114 '<p><strong>' . __( 'For more information:' ) . '</strong></p>' . 115 '<p>' . __( '<a href="http://codex.wordpress.org/Administration_Panels#Comments" target="_blank">Comments Documentation</a>' ) . '</p>' . 116 '<p>' . __( '<a href="http://codex.wordpress.org/Comment_Spam" target="_blank">Comment Spam Documentation</a>') . '</p>' . 117 '<p>' . __( '<a href="http://codex.wordpress.org/Keyboard_Shortcuts" target="_blank">Keyboard Shortcuts Documentation</a>') . '</p>' . 118 '<p>' . __( '<a href="http://wordpress.org/support/" target="_blank">Support Forums</a>') . '</p>' 119 ); 120 require_once ('./admin-header.php'); 121 122 $mode = ( empty($_GET['mode']) ) ? 'detail' : esc_attr($_GET['mode']); 123 124 $comment_status = isset($_REQUEST['comment_status']) ? $_REQUEST['comment_status'] : 'all'; 125 if ( !in_array($comment_status, array('all', 'moderated', 'approved', 'spam', 'trash')) ) 126 $comment_status = 'all'; 127 128 $comment_type = !empty($_GET['comment_type']) ? esc_attr($_GET['comment_type']) : ''; 129 130 $search_dirty = ( isset($_GET['s']) ) ? $_GET['s'] : ''; 131 $search = esc_attr( $search_dirty ); ?> 132 133 <div class="wrap"> 134 <?php screen_icon(); ?> 135 <h2><?php echo esc_html( $title ); 136 if ( isset($_GET['s']) && $_GET['s'] ) 137 printf( '<span class="subtitle">' . sprintf( __( 'Search results for “%s”' ), wp_html_excerpt( esc_html( stripslashes( $_GET['s'] ) ), 50 ) ) . '</span>' ); ?> 138 </h2> 139 140 <?php 141 if ( isset( $_GET['error'] ) ) { 142 $error = (int) $_GET['error']; 143 $error_msg = ''; 144 switch ( $error ) { 145 case 1 : 146 $error_msg = __( 'Oops, no comment with this ID.' ); 147 break; 148 case 2 : 149 $error_msg = __( 'You are not allowed to edit comments on this post.' ); 150 break; 151 } 152 if ( $error_msg ) 153 echo '<div id="moderated" class="error"><p>' . $error_msg . '</p></div>'; 154 } 155 156 if ( isset($_GET['approved']) || isset($_GET['deleted']) || isset($_GET['trashed']) || isset($_GET['untrashed']) || isset($_GET['spammed']) || isset($_GET['unspammed']) || isset($_GET['same']) ) { 157 $approved = isset( $_GET['approved'] ) ? (int) $_GET['approved'] : 0; 158 $deleted = isset( $_GET['deleted'] ) ? (int) $_GET['deleted'] : 0; 159 $trashed = isset( $_GET['trashed'] ) ? (int) $_GET['trashed'] : 0; 160 $untrashed = isset( $_GET['untrashed'] ) ? (int) $_GET['untrashed'] : 0; 161 $spammed = isset( $_GET['spammed'] ) ? (int) $_GET['spammed'] : 0; 162 $unspammed = isset( $_GET['unspammed'] ) ? (int) $_GET['unspammed'] : 0; 163 $same = isset( $_GET['same'] ) ? (int) $_GET['same'] : 0; 164 165 if ( $approved > 0 || $deleted > 0 || $trashed > 0 || $untrashed > 0 || $spammed > 0 || $unspammed > 0 || $same > 0 ) { 166 if ( $approved > 0 ) 167 $messages[] = sprintf( _n( '%s comment approved', '%s comments approved', $approved ), $approved ); 168 169 if ( $spammed > 0 ) { 170 $ids = isset($_GET['ids']) ? $_GET['ids'] : 0; 171 $messages[] = sprintf( _n( '%s comment marked as spam.', '%s comments marked as spam.', $spammed ), $spammed ) . ' <a href="' . esc_url( wp_nonce_url( "edit-comments.php?doaction=undo&action=unspam&ids=$ids", "bulk-comments" ) ) . '">' . __('Undo') . '</a><br />'; 172 } 173 174 if ( $unspammed > 0 ) 175 $messages[] = sprintf( _n( '%s comment restored from the spam', '%s comments restored from the spam', $unspammed ), $unspammed ); 176 177 if ( $trashed > 0 ) { 178 $ids = isset($_GET['ids']) ? $_GET['ids'] : 0; 179 $messages[] = sprintf( _n( '%s comment moved to the Trash.', '%s comments moved to the Trash.', $trashed ), $trashed ) . ' <a href="' . esc_url( wp_nonce_url( "edit-comments.php?doaction=undo&action=untrash&ids=$ids", "bulk-comments" ) ) . '">' . __('Undo') . '</a><br />'; 180 } 181 182 if ( $untrashed > 0 ) 183 $messages[] = sprintf( _n( '%s comment restored from the Trash', '%s comments restored from the Trash', $untrashed ), $untrashed ); 184 185 if ( $deleted > 0 ) 186 $messages[] = sprintf( _n( '%s comment permanently deleted', '%s comments permanently deleted', $deleted ), $deleted ); 187 188 if ( $same > 0 && $comment = get_comment( $same ) ) { 189 switch ( $comment->comment_approved ) { 190 case '1' : 191 $messages[] = __('This comment is already approved.') . ' <a href="' . esc_url( admin_url( "comment.php?action=editcomment&c=$same" ) ) . '">' . __( 'Edit comment' ) . '</a>'; 192 break; 193 case 'trash' : 194 $messages[] = __( 'This comment is already in the Trash.' ) . ' <a href="' . esc_url( admin_url( 'edit-comments.php?comment_status=trash' ) ) . '"> ' . __( 'View Trash' ) . '</a>'; 195 break; 196 case 'spam' : 197 $messages[] = __( 'This comment is already marked as spam.' ) . ' <a href="' . esc_url( admin_url( "comment.php?action=editcomment&c=$same" ) ) . '">' . __( 'Edit comment' ) . '</a>'; 198 break; 199 } 200 } 201 202 echo '<div id="moderated" class="updated"><p>' . implode( "<br/>\n", $messages ) . '</p></div>'; 203 } 204 } 205 ?> 206 207 <form id="comments-form" action="" method="get"> 208 <ul class="subsubsub"> 209 <?php 210 $status_links = array(); 211 $num_comments = ( $post_id ) ? wp_count_comments( $post_id ) : wp_count_comments(); 212 //, number_format_i18n($num_comments->moderated) ), "<span class='comment-count'>" . number_format_i18n($num_comments->moderated) . "</span>"), 213 //, number_format_i18n($num_comments->spam) ), "<span class='spam-comment-count'>" . number_format_i18n($num_comments->spam) . "</span>") 214 $stati = array( 215 'all' => _nx_noop('All', 'All', 'comments'), // singular not used 216 'moderated' => _n_noop('Pending <span class="count">(<span class="pending-count">%s</span>)</span>', 'Pending <span class="count">(<span class="pending-count">%s</span>)</span>'), 217 'approved' => _n_noop('Approved', 'Approved'), // singular not used 218 'spam' => _n_noop('Spam <span class="count">(<span class="spam-count">%s</span>)</span>', 'Spam <span class="count">(<span class="spam-count">%s</span>)</span>'), 219 'trash' => _n_noop('Trash <span class="count">(<span class="trash-count">%s</span>)</span>', 'Trash <span class="count">(<span class="trash-count">%s</span>)</span>') 220 ); 221 222 if ( !EMPTY_TRASH_DAYS ) 223 unset($stati['trash']); 224 225 $link = 'edit-comments.php'; 226 if ( !empty($comment_type) && 'all' != $comment_type ) 227 $link = add_query_arg( 'comment_type', $comment_type, $link ); 228 229 foreach ( $stati as $status => $label ) { 230 $class = ( $status == $comment_status ) ? ' class="current"' : ''; 231 232 if ( !isset( $num_comments->$status ) ) 233 $num_comments->$status = 10; 234 $link = add_query_arg( 'comment_status', $status, $link ); 235 if ( $post_id ) 236 $link = add_query_arg( 'p', absint( $post_id ), $link ); 237 /* 238 // I toyed with this, but decided against it. Leaving it in here in case anyone thinks it is a good idea. ~ Mark 239 if ( !empty( $_GET['s'] ) ) 240 $link = add_query_arg( 's', esc_attr( stripslashes( $_GET['s'] ) ), $link ); 241 */ 242 if ( isset( $label[2] ) ) 243 $translated_label = _nx( $label[0], $label[1], $num_comments->$status, $label[2] ); 244 else 245 $translated_label = _n( $label[0], $label[1], $num_comments->$status ); 246 $status_links[] = "<li class='$status'><a href='$link'$class>" . sprintf( 247 $translated_label, 248 number_format_i18n( $num_comments->$status ) 249 ) . '</a>'; 250 } 251 252 $status_links = apply_filters( 'comment_status_links', $status_links ); 253 254 echo implode( " |</li>\n", $status_links) . '</li>'; 255 unset($status_links); 256 ?> 257 </ul> 258 259 <p class="search-box"> 260 <label class="screen-reader-text" for="comment-search-input"><?php _e( 'Search Comments' ); ?>:</label> 261 <input type="text" id="comment-search-input" name="s" value="<?php _admin_search_query(); ?>" /> 262 <input type="submit" value="<?php esc_attr_e( 'Search Comments' ); ?>" class="button" /> 263 </p> 264 265 <?php 266 $comments_per_page = (int) get_user_option( 'edit_comments_per_page' ); 267 if ( empty( $comments_per_page ) || $comments_per_page < 1 ) 268 $comments_per_page = 20; 269 $comments_per_page = apply_filters( 'comments_per_page', $comments_per_page, $comment_status ); 270 271 if ( isset( $_GET['apage'] ) ) 272 $page = abs( (int) $_GET['apage'] ); 273 else 274 $page = 1; 275 276 $start = $offset = ( $page - 1 ) * $comments_per_page; 277 278 list($_comments, $total) = _wp_get_comment_list( $comment_status, $search_dirty, $start, $comments_per_page + 8, $post_id, $comment_type ); // Grab a few extra 279 280 $_comment_post_ids = array(); 281 foreach ( $_comments as $_c ) { 282 $_comment_post_ids[] = $_c->comment_post_ID; 283 } 284 285 $_comment_pending_count = get_pending_comments_num($_comment_post_ids); 286 287 $comments = array_slice($_comments, 0, $comments_per_page); 288 $extra_comments = array_slice($_comments, $comments_per_page); 289 290 $page_links = paginate_links( array( 291 'base' => add_query_arg( 'apage', '%#%' ), 292 'format' => '', 293 'prev_text' => __('«'), 294 'next_text' => __('»'), 295 'total' => ceil($total / $comments_per_page), 296 'current' => $page 297 )); 298 299 ?> 300 301 <input type="hidden" name="mode" value="<?php echo esc_attr($mode); ?>" /> 302 <?php if ( $post_id ) : ?> 303 <input type="hidden" name="p" value="<?php echo esc_attr( intval( $post_id ) ); ?>" /> 304 <?php endif; ?> 305 <input type="hidden" name="comment_status" value="<?php echo esc_attr($comment_status); ?>" /> 306 <input type="hidden" name="pagegen_timestamp" value="<?php echo esc_attr(current_time('mysql', 1)); ?>" /> 307 308 <div class="tablenav"> 309 310 <?php if ( $page_links ) : ?> 311 <div class="tablenav-pages"><?php $page_links_text = sprintf( '<span class="displaying-num">' . __( 'Displaying %s–%s of %s' ) . '</span>%s', 312 number_format_i18n( $start + 1 ), 313 number_format_i18n( min( $page * $comments_per_page, $total ) ), 314 '<span class="total-type-count">' . number_format_i18n( $total ) . '</span>', 315 $page_links 316 ); echo $page_links_text; ?></div> 317 <input type="hidden" name="_total" value="<?php echo esc_attr($total); ?>" /> 318 <input type="hidden" name="_per_page" value="<?php echo esc_attr($comments_per_page); ?>" /> 319 <input type="hidden" name="_page" value="<?php echo esc_attr($page); ?>" /> 320 <?php endif; ?> 321 322 <?php if ( $comments ) : ?> 323 <div class="alignleft actions"> 324 <select name="action"> 325 <option value="-1" selected="selected"><?php _e('Bulk Actions') ?></option> 326 <?php if ( 'all' == $comment_status || 'approved' == $comment_status ): ?> 327 <option value="unapprove"><?php _e('Unapprove'); ?></option> 328 <?php endif; ?> 329 <?php if ( 'all' == $comment_status || 'moderated' == $comment_status || 'spam' == $comment_status ): ?> 330 <option value="approve"><?php _e('Approve'); ?></option> 331 <?php endif; ?> 332 <?php if ( 'all' == $comment_status || 'approved' == $comment_status || 'moderated' == $comment_status ): ?> 333 <option value="spam"><?php _ex('Mark as Spam', 'comment'); ?></option> 334 <?php endif; ?> 335 <?php if ( 'trash' == $comment_status ): ?> 336 <option value="untrash"><?php _e('Restore'); ?></option> 337 <?php elseif ( 'spam' == $comment_status ): ?> 338 <option value="unspam"><?php _ex('Not Spam', 'comment'); ?></option> 339 <?php endif; ?> 340 <?php if ( 'trash' == $comment_status || 'spam' == $comment_status || !EMPTY_TRASH_DAYS ): ?> 341 <option value="delete"><?php _e('Delete Permanently'); ?></option> 342 <?php else: ?> 343 <option value="trash"><?php _e('Move to Trash'); ?></option> 344 <?php endif; ?> 345 </select> 346 <input type="submit" name="doaction" id="doaction" value="<?php esc_attr_e('Apply'); ?>" class="button-secondary apply" /> 347 <?php wp_nonce_field('bulk-comments'); ?> 348 349 <?php endif; ?> 350 351 <select name="comment_type"> 352 <option value="all"><?php _e('Show all comment types'); ?></option> 353 <?php 354 $comment_types = apply_filters( 'admin_comment_types_dropdown', array( 355 'comment' => __('Comments'), 356 'pings' => __('Pings'), 357 ) ); 358 359 foreach ( $comment_types as $type => $label ) { 360 echo " <option value='" . esc_attr($type) . "'"; 361 selected( $comment_type, $type ); 362 echo ">$label</option>\n"; 363 } 364 ?> 365 </select> 366 <input type="submit" id="post-query-submit" value="<?php esc_attr_e('Filter'); ?>" class="button-secondary" /> 367 368 <?php if ( isset($_GET['apage']) ) { ?> 369 <input type="hidden" name="apage" value="<?php echo esc_attr( absint( $_GET['apage'] ) ); ?>" /> 370 <?php } 371 372 if ( ( 'spam' == $comment_status || 'trash' == $comment_status) && current_user_can ('moderate_comments') ) { 373 wp_nonce_field('bulk-destroy', '_destroy_nonce'); 374 if ( 'spam' == $comment_status && current_user_can('moderate_comments') ) { ?> 375 <input type="submit" name="delete_all" id="delete_all" value="<?php esc_attr_e('Empty Spam'); ?>" class="button-secondary apply" /> 376 <?php } elseif ( 'trash' == $comment_status && current_user_can('moderate_comments') ) { ?> 377 <input type="submit" name="delete_all" id="delete_all" value="<?php esc_attr_e('Empty Trash'); ?>" class="button-secondary apply" /> 378 <?php } 379 } ?> 380 <?php do_action('manage_comments_nav', $comment_status); ?> 381 </div> 382 383 <br class="clear" /> 384 385 </div> 386 387 <div class="clear"></div> 388 <?php if ( $comments ) { ?> 389 390 <table class="widefat comments fixed" cellspacing="0"> 391 <thead> 392 <tr> 393 <?php print_column_headers('edit-comments'); ?> 394 </tr> 395 </thead> 396 397 <tfoot> 398 <tr> 399 <?php print_column_headers('edit-comments', false); ?> 400 </tr> 401 </tfoot> 402 403 <tbody id="the-comment-list" class="list:comment"> 404 <?php 405 foreach ($comments as $comment) 406 _wp_comment_row( $comment->comment_ID, $mode, $comment_status ); 407 ?> 408 </tbody> 409 <tbody id="the-extra-comment-list" class="list:comment" style="display: none;"> 410 <?php 411 foreach ($extra_comments as $comment) 412 _wp_comment_row( $comment->comment_ID, $mode, $comment_status ); 413 ?> 414 </tbody> 415 </table> 416 417 <div class="tablenav"> 418 <?php 419 if ( $page_links ) 420 echo "<div class='tablenav-pages'>$page_links_text</div>"; 421 ?> 422 423 <div class="alignleft actions"> 424 <select name="action2"> 425 <option value="-1" selected="selected"><?php _e('Bulk Actions') ?></option> 426 <?php if ( 'all' == $comment_status || 'approved' == $comment_status ): ?> 427 <option value="unapprove"><?php _e('Unapprove'); ?></option> 428 <?php endif; ?> 429 <?php if ( 'all' == $comment_status || 'moderated' == $comment_status || 'spam' == $comment_status ): ?> 430 <option value="approve"><?php _e('Approve'); ?></option> 431 <?php endif; ?> 432 <?php if ( 'all' == $comment_status || 'approved' == $comment_status || 'moderated' == $comment_status ): ?> 433 <option value="spam"><?php _ex('Mark as Spam', 'comment'); ?></option> 434 <?php endif; ?> 435 <?php if ( 'trash' == $comment_status ): ?> 436 <option value="untrash"><?php _e('Restore'); ?></option> 437 <?php endif; ?> 438 <?php if ( 'trash' == $comment_status || 'spam' == $comment_status || !EMPTY_TRASH_DAYS ): ?> 439 <option value="delete"><?php _e('Delete Permanently'); ?></option> 440 <?php elseif ( 'spam' == $comment_status ): ?> 441 <option value="unspam"><?php _ex('Not Spam', 'comment'); ?></option> 442 <?php else: ?> 443 <option value="trash"><?php _e('Move to Trash'); ?></option> 444 <?php endif; ?> 445 </select> 446 <input type="submit" name="doaction2" id="doaction2" value="<?php esc_attr_e('Apply'); ?>" class="button-secondary apply" /> 447 448 <?php if ( 'spam' == $comment_status && current_user_can('moderate_comments') ) { ?> 449 <input type="submit" name="delete_all2" id="delete_all2" value="<?php esc_attr_e('Empty Spam'); ?>" class="button-secondary apply" /> 450 <?php } elseif ( 'trash' == $comment_status && current_user_can('moderate_comments') ) { ?> 451 <input type="submit" name="delete_all2" id="delete_all2" value="<?php esc_attr_e('Empty Trash'); ?>" class="button-secondary apply" /> 452 <?php } ?> 453 <?php do_action('manage_comments_nav', $comment_status); ?> 454 </div> 455 456 <br class="clear" /> 457 </div> 458 459 </form> 460 461 <form id="get-extra-comments" method="post" action="" class="add:the-extra-comment-list:" style="display: none;"> 462 <input type="hidden" name="s" value="<?php echo esc_attr($search); ?>" /> 463 <input type="hidden" name="mode" value="<?php echo esc_attr($mode); ?>" /> 464 <input type="hidden" name="comment_status" value="<?php echo esc_attr($comment_status); ?>" /> 465 <input type="hidden" name="page" value="<?php echo esc_attr($page); ?>" /> 466 <input type="hidden" name="per_page" value="<?php echo esc_attr($comments_per_page); ?>" /> 467 <input type="hidden" name="p" value="<?php echo esc_attr( $post_id ); ?>" /> 468 <input type="hidden" name="comment_type" value="<?php echo esc_attr( $comment_type ); ?>" /> 469 <?php wp_nonce_field( 'add-comment', '_ajax_nonce', false ); ?> 470 </form> 471 472 <div id="ajax-response"></div> 473 474 <?php } elseif ( 'moderated' == $comment_status ) { ?> 475 <p><?php _e('No comments awaiting moderation… yet.') ?></p> 476 </div> 477 </form> 478 479 <?php } else { ?> 480 <p><?php _e('No comments found.') ?></p> 481 </div> 482 </form> 483 484 <?php } ?> 485 </div> 486 487 <?php 488 wp_comment_reply('-1', true, 'detail'); 489 wp_comment_trashnotice(); 490 include ('./admin-footer.php'); ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
| Generated: Thu Oct 14 05:12:05 2010 | Cross-referenced by PHPXref 0.7 |