Changeset 24081
- Timestamp:
- 04/25/2013 02:44:23 AM (12 years ago)
- Location:
- trunk/wp-admin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/edit-form-advanced.php
r24063 r24081 140 140 if ( ! $post_format ) { 141 141 $post_format = 'standard'; 142 if ( 'auto-draft' == $post->post_status ) 142 143 if ( ! empty( $_REQUEST['format'] ) && in_array( $_REQUEST['format'], get_post_format_slugs() ) ) 144 $post_format = $_REQUEST['format']; 145 elseif ( 'auto-draft' == $post->post_status ) 143 146 $post_format_set_class = ''; 144 147 } -
trunk/wp-admin/includes/screen.php
r24039 r24081 149 149 */ 150 150 function get_screen_icon( $screen = '' ) { 151 global $post_ID;152 151 if ( empty( $screen ) ) 153 152 $screen = get_current_screen(); … … 169 168 $class .= ' ' . sanitize_html_class( 'icon32-posts-' . $screen->post_type ); 170 169 171 if ( $post_ID ) { 172 $format = get_post_format( $post_ID ); 173 if ( $format ) 174 $class .= ' wp-format-' . $format; 170 if ( 'post' == $screen->id ) { 171 $post_format = get_post_format(); 172 if ( ! $post_format && ! empty( $_REQUEST['format'] ) && in_array( $_REQUEST['format'], get_post_format_slugs() ) ) 173 $post_format = $_REQUEST['format']; 174 175 if ( $post_format ) 176 $class .= ' wp-format-' . $post_format; 175 177 } 176 178 }
Note: See TracChangeset
for help on using the changeset viewer.