Make WordPress Core

Opened 13 years ago

Closed 12 years ago

#20136 closed defect (bug) (duplicate)

ms-files.php sets *.webm mimetype incorrectly

Reported by: braydonf's profile braydonf Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Multisite Keywords:
Focuses: Cc:

Description

The content-type of *.webm files is incorrectly being set to image/webm by ms-files.php for multisite networks on uploaded *.webm videos in the media library.

Change History (6)

#1 @solarissmoke
13 years ago

  • Keywords reporter-feedback close added

There is no reference to .webm in core... so you must be filtering the list of allowed file extensions/MIME types in order to be able to upload WebM videos in the first place?

#2 @braydonf
13 years ago

In one of the themes I have done so yes, using this in functions.php

    add_filter( 'upload_mimes', 'custom_mimes' );

    function custom_mimes( $mimes ){
        $mimes['webm'] = 'video/webm';

        return $mimes;
    }

However in the rewrite to wp-includes/ms-files.php, the filter isn't being run since it is "outside" of a site.

Last edited 13 years ago by ocean90 (previous) (diff)

#3 @braydonf
13 years ago

The rewrite is also preventing some aspects of the video to be displayed correctly, since it's not being served directly from Apache. This is part of a larger issue.

#4 @solarissmoke
13 years ago

  • Keywords reporter-feedback close removed

Ah, I see the problem now.

#5 @ocean90
13 years ago

  • Severity changed from major to normal

Related: #14659

#6 @wonderboymusic
12 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to duplicate
  • Status changed from new to closed

Patch attached to #14659

Note: See TracTickets for help on using tickets.