Changeset 3660 for trunk/wp-admin/edit-comments.php
- Timestamp:
- 03/29/2006 01:51:55 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/edit-comments.php
r3652 r3660 134 134 </li> 135 135 136 <?php } // end foreach ?>136 <?php } // end foreach($comment) ?> 137 137 </ol> 138 138 … … 140 140 141 141 <?php 142 } else { 142 } else { //no comments to show 143 143 144 144 ?> … … 163 163 foreach ($comments as $comment) { 164 164 $authordata = get_userdata($wpdb->get_var("SELECT post_author FROM $wpdb->posts WHERE ID = $comment->comment_post_ID")); 165 $comment_status = wp_get_comment_status($comment->comment_ID); 165 166 $class = ('alternate' == $class) ? '' : 'alternate'; 166 ?> 167 <tr class='<?php echo $class; ?>'> 167 $class .= ('unapproved' == $comment_status) ? ' unapproved' : ''; 168 ?> 169 <tr id="comment-<?php echo $comment->comment_ID; ?>" class='<?php echo $class; ?>'> 168 170 <td><?php if ( current_user_can('edit_post', $comment->comment_post_ID) ) { ?><input type="checkbox" name="delete_comments[]" value="<?php echo $comment->comment_ID; ?>" /><?php } ?></td> 169 171 <td><?php comment_author_link() ?></td> … … 171 173 <td><a href="http://ws.arin.net/cgi-bin/whois.pl?queryinput=<?php comment_author_IP() ?>"><?php comment_author_IP() ?></a></td> 172 174 <td><?php comment_excerpt(); ?></td> 173 <td><a href="<?php echo get_permalink($comment->comment_post_ID); ?>#comment-<?php comment_ID() ?>" class="edit"><?php _e('View') ?></a></td> 175 <td> 176 <?php if ('unapproved' == $comment_status) { ?> 177 (Unapproved) 178 <?php } else { ?> 179 <a href="<?php echo get_permalink($comment->comment_post_ID); ?>#comment-<?php comment_ID() ?>" class="edit"><?php _e('View') ?></a> 180 <?php } ?> 181 </td> 174 182 <td><?php if ( current_user_can('edit_post', $comment->comment_post_ID) ) { 175 183 echo "<a href='comment.php?action=editcomment&comment=$comment->comment_ID' class='edit'>" . __('Edit') . "</a>"; } ?></td> 176 184 <td><?php if ( current_user_can('edit_post', $comment->comment_post_ID) ) { 177 echo "<a href=\"comment.php?action=deletecomment&p=".$comment->comment_post_ID."&comment=".$comment->comment_ID."\" onclick=\"return confirm('" . sprintf(__("You are about to delete this comment by \'%s\'\\n \'Cancel\' to stop, \'OK\' to delete."), $comment->comment_author) . "')\" class='delete'>" . __('Delete') . "</a>"; } ?></td> 185 echo "<a href=\"comment.php?action=deletecomment&p=".$comment->comment_post_ID."&comment=".$comment->comment_ID."\" onclick=\"return deleteSomething( 'comment', $comment->comment_ID, '" . sprintf(__("You are about to delete this comment by "%s".\\n"Cancel" to stop, "OK" to delete."), wp_specialchars( $comment->comment_author, 1 )) . "' );\" class='edit'>" . __('Delete') . "</a> "; 186 } ?></td> 178 187 </tr> 179 188 <?php … … 184 193 <input type="submit" name="spam_button" value="<?php _e('Mark Checked Comments as Spam »') ?>" onclick="return confirm('<?php _e("You are about to mark these comments as spam \\n \'Cancel\' to stop, \'OK\' to mark as spam.") ?>')" /></p> 185 194 </form> 195 <div id="ajax-response"></div> 186 196 <?php 187 197 } else {
Note: See TracChangeset
for help on using the changeset viewer.