Changeset 34002
- Timestamp:
- 09/10/2015 05:17:22 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/media-new.php
r32974 r34002 26 26 27 27 if ( $_POST ) { 28 $location = 'upload.php';29 28 if ( isset($_POST['html-upload']) && !empty($_FILES) ) { 30 29 check_admin_referer('media-form'); 31 30 // Upload File button was clicked 32 $id = media_handle_upload( 'async-upload', $post_id ); 33 if ( is_wp_error( $id ) ) 34 $location .= '?message=3'; 31 $upload_id = media_handle_upload( 'async-upload', $post_id ); 32 if ( is_wp_error( $upload_id ) ) { 33 wp_die( $upload_id ); 34 } 35 35 } 36 wp_redirect( admin_url( $location) );36 wp_redirect( admin_url( 'upload.php' ) ); 37 37 exit; 38 38 }
Note: See TracChangeset
for help on using the changeset viewer.