WordPress.org

Make WordPress Core

Ticket #3219: 3219.wp_handle_upload_import.diff

File 3219.wp_handle_upload_import.diff, 548 bytes (added by westi, 12 years ago)

Patch to fix wp_handle_upload_import

  • wp-admin/admin-functions.php

     
    19441944                return $file;
    19451945
    19461946        $url = $file['url'];
     1947        $type = $file['type'];
    19471948        $file = addslashes( $file['file'] );
    19481949        $filename = basename($file);
    19491950
     
    19511952        $object = array(
    19521953                'post_title' => $filename,
    19531954                'post_content' => $url,
    1954                 'post_mime_type' => 'import',
     1955                'post_mime_type' => $type,
    19551956                'guid' => $url
    19561957        );
    19571958