Ticket #24096: 24096.4.diff
File 24096.4.diff, 2.1 KB (added by , 11 years ago) |
---|
-
src/wp-admin/includes/class-wp-posts-list-table.php
1034 1034 <?php endif; // 'post' && $can_publish && current_user_can( 'edit_others_cap' ) ?> 1035 1035 1036 1036 </div> 1037 1038 <?php 1039 1040 if ( $bulk && post_type_supports( $screen->post_type, 'post-formats' ) ) { 1041 $all_post_formats = get_post_format_strings(); 1042 1043 ?> 1044 <label class="alignleft" for="post_format"> 1045 <span class="title"><?php _ex( 'Format', 'post format' ); ?></span> 1046 <select name="post_format"> 1047 <option value="-1"><?php _e( '— No Change —' ); ?></option> 1048 <?php 1049 1050 foreach ( $all_post_formats as $slug => $format ) { 1051 ?> 1052 <option value="<?php echo esc_attr( $slug ); ?>"><?php echo esc_html( $format ); ?></option> 1053 <?php 1054 } 1055 1056 ?> 1057 </select></label> 1058 <?php 1059 1060 } 1061 1062 ?> 1063 1037 1064 </div></fieldset> 1038 1065 1039 1066 <?php -
src/wp-admin/includes/post.php
325 325 326 326 $post_IDs = array_map( 'intval', (array) $post_data['post'] ); 327 327 328 $reset = array( 'post_author', 'post_status', 'post_password', 'post_parent', 'page_template', 'comment_status', 'ping_status', 'keep_private', 'tax_input', 'post_category', 'sticky' ); 328 $reset = array( 329 'post_author', 'post_status', 'post_password', 330 'post_parent', 'page_template', 'comment_status', 331 'ping_status', 'keep_private', 'tax_input', 332 'post_category', 'sticky', 'post_format' 333 ); 334 329 335 foreach ( $reset as $field ) { 330 336 if ( isset($post_data[$field]) && ( '' == $post_data[$field] || -1 == $post_data[$field] ) ) 331 337 unset($post_data[$field]); … … 419 425 else 420 426 unstick_post( $post_ID ); 421 427 } 428 429 if ( isset( $post_data['post_format'] ) ) 430 set_post_format( $post_ID, $post_data['post_format'] ); 422 431 } 423 432 424 433 return array( 'updated' => $updated, 'skipped' => $skipped, 'locked' => $locked );