Changeset 36588
- Timestamp:
- 02/19/2016 07:13:59 PM (9 years ago)
- Location:
- trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/comment.php
r36173 r36588 82 82 $comment_id = absint( $_GET['c'] ); 83 83 84 if ( ! $comment = get_comment_to_edit( $comment_id ) ) {84 if ( ! $comment = get_comment( $comment_id ) ) { 85 85 wp_redirect( admin_url('edit-comments.php?error=1') ); 86 86 die(); … … 143 143 } 144 144 if ( $message ) { 145 echo '<div class="notice notice-info"><p>' . $message . '</p></div>';145 echo '<div id="message" class="notice notice-info"><p>' . $message . '</p></div>'; 146 146 } 147 147 } 148 148 ?> 149 < p><strong><?php _e('Caution:'); ?></strong> <?php echo $caution_msg; ?></p>149 <div id="message" class="notice notice-warning"><p><strong><?php _e( 'Caution:' ); ?></strong> <?php echo $caution_msg; ?></p></div> 150 150 151 151 <table class="form-table comment-ays"> 152 152 <tr> 153 153 <th scope="row"><?php _e('Author'); ?></th> 154 <td><?php echo $comment->comment_author; ?></td>155 </tr> 156 <?php if ( $comment->comment_author_email) { ?>154 <td><?php comment_author( $comment ); ?></td> 155 </tr> 156 <?php if ( get_comment_author_email( $comment ) ) { ?> 157 157 <tr> 158 158 <th scope="row"><?php _e('Email'); ?></th> 159 <td><?php echo $comment->comment_author_email; ?></td>159 <td><?php comment_author_email( $comment ); ?></td> 160 160 </tr> 161 161 <?php } ?> 162 <?php if ( $comment->comment_author_url) { ?>162 <?php if ( get_comment_author_url( $comment ) ) { ?> 163 163 <tr> 164 164 <th scope="row"><?php _e('URL'); ?></th> 165 <td><a href="<?php echo $comment->comment_author_url; ?>"><?php echo $comment->comment_author_url; ?></a></td>165 <td><a href="<?php comment_author_url( $comment ); ?>"><?php comment_author_url( $comment ); ?></a></td> 166 166 </tr> 167 167 <?php } ?> … … 195 195 <th scope="row"><?php _e( 'Submitted on' ); ?></th> 196 196 <td> 197 <a href="<?php echo esc_url( get_comment_link( $comment ) ); ?>"><?php 198 /* translators: 1: comment date, 2: comment time */ 199 printf( __( '%1$s at %2$s' ), 200 /* translators: comment date format. See http://php.net/date */ 201 get_comment_date( __( 'Y/m/d' ), $comment ), 202 get_comment_date( __( 'g:i a' ), $comment ) 203 ); 204 ?></a> 197 <?php 198 /* translators: 1: comment date, 2: comment time */ 199 $submitted = sprintf( __( '%1$s at %2$s' ), 200 /* translators: comment date format. See http://php.net/date */ 201 get_comment_date( __( 'Y/m/d' ), $comment ), 202 get_comment_date( __( 'g:i a' ), $comment ) 203 ); 204 if ( 'approved' === wp_get_comment_status( $comment ) && ! empty ( $comment->comment_post_ID ) ) { 205 echo '<a href="' . esc_url( get_comment_link( $comment ) ) . '">' . $submitted . '</a>'; 206 } else { 207 echo $submitted; 208 } 209 ?> 205 210 </td> 206 211 </tr> 207 212 <tr> 208 213 <th scope="row"><?php /* translators: field name in comment form */ _ex('Comment', 'noun'); ?></th> 209 <td><?php echo $comment->comment_content; ?></td> 214 <td> 215 <?php echo $comment->comment_content; ?> 216 <p><a href="<?php echo admin_url( "comment.php?action=editcomment&c={$comment->comment_ID}" ); ?>"><?php esc_attr_e( 'Edit' ); ?></a></p> 217 </td> 210 218 </tr> 211 219 </table> -
trunk/src/wp-admin/css/edit.css
r36537 r36588 1147 1147 .comment-ays td { 1148 1148 padding: 10px 15px; 1149 } 1150 1151 .comment-ays td p:last-of-type { 1152 margin-top: 10px; 1149 1153 } 1150 1154 -
trunk/src/wp-includes/pluggable.php
r36446 r36588 1500 1500 if ( user_can( $post->post_author, 'edit_comment', $comment->comment_ID ) ) { 1501 1501 if ( EMPTY_TRASH_DAYS ) { 1502 $notify_message .= sprintf( __( 'Trash it: %s'), admin_url("comment.php?action=trash&c={$comment->comment_ID}") ) . "\r\n";1502 $notify_message .= sprintf( __( 'Trash it: %s' ), admin_url( "comment.php?action=trash&c={$comment->comment_ID}#wpbody-content" ) ) . "\r\n"; 1503 1503 } else { 1504 $notify_message .= sprintf( __( 'Delete it: %s'), admin_url("comment.php?action=delete&c={$comment->comment_ID}") ) . "\r\n";1504 $notify_message .= sprintf( __( 'Delete it: %s' ), admin_url( "comment.php?action=delete&c={$comment->comment_ID}#wpbody-content" ) ) . "\r\n"; 1505 1505 } 1506 $notify_message .= sprintf( __( 'Spam it: %s'), admin_url("comment.php?action=spam&c={$comment->comment_ID}") ) . "\r\n";1506 $notify_message .= sprintf( __( 'Spam it: %s' ), admin_url( "comment.php?action=spam&c={$comment->comment_ID}#wpbody-content" ) ) . "\r\n"; 1507 1507 } 1508 1508 … … 1641 1641 } 1642 1642 1643 $notify_message .= sprintf( __('Approve it: %s'), admin_url("comment.php?action=approve&c=$comment_id") ) . "\r\n"; 1643 $notify_message .= sprintf( __( 'Approve it: %s' ), admin_url( "comment.php?action=approve&c={$comment_id}#wpbody-content" ) ) . "\r\n"; 1644 1644 1645 if ( EMPTY_TRASH_DAYS ) 1645 $notify_message .= sprintf( __( 'Trash it: %s'), admin_url("comment.php?action=trash&c=$comment_id") ) . "\r\n";1646 $notify_message .= sprintf( __( 'Trash it: %s' ), admin_url( "comment.php?action=trash&c={$comment_id}#wpbody-content" ) ) . "\r\n"; 1646 1647 else 1647 $notify_message .= sprintf( __('Delete it: %s'), admin_url("comment.php?action=delete&c=$comment_id") ) . "\r\n"; 1648 $notify_message .= sprintf( __('Spam it: %s'), admin_url("comment.php?action=spam&c=$comment_id") ) . "\r\n"; 1648 $notify_message .= sprintf( __( 'Delete it: %s' ), admin_url( "comment.php?action=delete&c={$comment_id}#wpbody-content" ) ) . "\r\n"; 1649 1650 $notify_message .= sprintf( __( 'Spam it: %s' ), admin_url( "comment.php?action=spam&c={$comment_id}#wpbody-content" ) ) . "\r\n"; 1649 1651 1650 1652 $notify_message .= sprintf( _n('Currently %s comment is waiting for approval. Please visit the moderation panel:', 1651 1653 'Currently %s comments are waiting for approval. Please visit the moderation panel:', $comments_waiting), number_format_i18n($comments_waiting) ) . "\r\n"; 1652 $notify_message .= admin_url( "edit-comments.php?comment_status=moderated") . "\r\n";1654 $notify_message .= admin_url( "edit-comments.php?comment_status=moderated#wpbody-content" ) . "\r\n"; 1653 1655 1654 1656 $subject = sprintf( __('[%1$s] Please moderate: "%2$s"'), $blogname, $post->post_title );
Note: See TracChangeset
for help on using the changeset viewer.