WordPress.org

Make WordPress Core


Ignore:
Timestamp:
05/30/2013 09:33:46 PM (7 years ago)
Author:
markjaquith
Message:

First pass at removing Post Format UI.

see #24452. fixes #24455.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/ajax-actions.php

    r24263 r24388  
    11271127}
    11281128
    1129 function wp_ajax_show_post_format_ui() {
    1130     if ( empty( $_POST['post_type'] ) )
    1131         wp_die( 0 );
    1132 
    1133     check_ajax_referer( 'show-post-format-ui_' . $_POST['post_type'], 'nonce' );
    1134 
    1135     if ( ! $post_type_object = get_post_type_object( $_POST['post_type'] ) )
    1136         wp_die( 0 );
    1137 
    1138     if ( ! current_user_can( $post_type_object->cap->edit_posts ) )
    1139         wp_die( -1 );
    1140 
    1141     update_user_option( get_current_user_id(), 'post_formats_' . $post_type_object->name, empty( $_POST['show'] ) ? 0 : 1 );
    1142 
    1143     wp_die( 1 );
    1144 }
    1145 
    11461129function wp_ajax_hidden_columns() {
    11471130    check_ajax_referer( 'screen-options-nonce', 'screenoptionnonce' );
Note: See TracChangeset for help on using the changeset viewer.