Changeset 18706
- Timestamp:
- 09/18/2011 09:11:28 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/class-wp-posts-list-table.php
r18527 r18706 465 465 function single_row( $a_post, $level = 0 ) { 466 466 global $post, $current_screen, $mode; 467 static $ rowclass;467 static $alternate; 468 468 469 469 $global_post = $post; … … 471 471 setup_postdata( $post ); 472 472 473 $rowclass = 'alternate' == $rowclass ? '' : 'alternate';474 $post_owner = ( get_current_user_id() == $post->post_author ? 'self' : 'other' );475 473 $edit_link = get_edit_post_link( $post->ID ); 476 474 $title = _draft_or_post_title(); 477 475 $post_type_object = get_post_type_object( $post->post_type ); 478 476 $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'; 477 478 $alternate = 'alternate' == $alternate ? '' : 'alternate'; 479 $classes = $alternate . ' iedit author-' . ( get_current_user_id() == $post->post_author ? 'self' : 'other' ); 481 480 ?> 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">481 <tr id="post-<?php echo $post->ID; ?>" class="<?php echo implode( ' ', get_post_class( $classes, $post->ID ) ); ?>" valign="top"> 483 482 <?php 484 483
Note: See TracChangeset
for help on using the changeset viewer.