Ticket #18516: 18516.2.diff
| File 18516.2.diff, 1.9 KB (added by , 14 years ago) |
|---|
-
wp-includes/post-template.php
327 327 $classes[] = $post->post_type; 328 328 $classes[] = 'type-' . $post->post_type; 329 329 $classes[] = 'status-' . $post->post_status; 330 331 // Did you write this or someone else? 332 $post_owner = ( get_current_user_id() == $post->post_author ? 'self' : 'other' ); 333 $classes[] = 'author-' . $post_owner; 330 334 331 335 // Post Format 332 336 if ( post_type_supports( $post->post_type, 'post-formats' ) ) { -
wp-admin/includes/class-wp-posts-list-table.php
471 471 setup_postdata( $post ); 472 472 473 473 $rowclass = 'alternate' == $rowclass ? '' : 'alternate'; 474 $post_owner = ( get_current_user_id() == $post->post_author ? 'self' : 'other' );475 474 $edit_link = get_edit_post_link( $post->ID ); 476 475 $title = _draft_or_post_title(); 477 476 $post_type_object = get_post_type_object( $post->post_type ); 478 477 $can_edit_post = current_user_can( $post_type_object->cap->edit_post, $post->ID ); 479 $post_format = get_post_format( $post->ID ); 480 $post_format_class = ( $post_format && !is_wp_error($post_format) ) ? 'format-' . sanitize_html_class( $post_format ) : 'format-default'; 478 $the_post_class = join( ' ', get_post_class( get_post_status( $post->ID ) ) ); 481 479 ?> 482 <tr id='post-<?php echo $post->ID; ?>' class='<?php echo trim( $rowclass . ' author-' . $post_owner . ' status-' . $post->post_status . ' ' . $post_format_class); ?> iedit' valign="top">480 <tr id='post-<?php echo $post->ID; ?>' class='<?php echo trim( $rowclass . ' ' . $the_post_class ); ?> iedit' valign="top"> 483 481 <?php 484 482 485 483 list( $columns, $hidden ) = $this->get_column_info();