Changeset 31121 for trunk/src/wp-admin/post-new.php
- Timestamp:
- 01/10/2015 05:28:46 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/post-new.php
r30356 r31121 10 10 require_once( dirname( __FILE__ ) . '/admin.php' ); 11 11 12 if ( !isset($_GET['post_type']) ) 12 global $post_type, $post_type_object, $post; 13 14 if ( ! isset( $_GET['post_type'] ) ) { 13 15 $post_type = 'post'; 14 elseif ( in_array( $_GET['post_type'], get_post_types( array('show_ui' => true ) ) ) ) 16 } elseif ( in_array( $_GET['post_type'], get_post_types( array('show_ui' => true ) ) ) ) { 15 17 $post_type = $_GET['post_type']; 16 else 18 } else { 17 19 wp_die( __('Invalid post type') ); 18 20 } 19 21 $post_type_object = get_post_type_object( $post_type ); 20 22
Note: See TracChangeset
for help on using the changeset viewer.