Make WordPress Core

Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#21594 closed defect (bug) (fixed)

Allow fetching unfiltered allowed mime types list

Reported by: ryan's profile ryan Owned by: ryan's profile ryan
Milestone: 3.5 Priority: normal
Severity: normal Version: 3.4.1
Component: General Keywords:
Focuses: Cc:


In #11668, do_enclose() gained mime type checking. It uses get_allowed_mime_types(). However, multisite installs greatly restrict the mime list when they run check_upload_mimes() on the upload_mimes filter. do_enclose() needs access to the full list. Introducing get_mime_types() and making get_allowed_mime_types() a wrapper could accommodate this.

Attachments (2)

21594.diff (8.8 KB) - added by ryan 12 years ago.
21594-ut.diff (1.8 KB) - added by ryan 12 years ago.

Download all attachments as: .zip

Change History (5)

#1 @ryan
12 years ago

While in here we can also address #21299.

12 years ago

12 years ago

#2 @ryan
12 years ago

  • Owner set to ryan
  • Resolution set to fixed
  • Status changed from new to closed

In [21541]:

Introduce wp_get_mime_types() for fetching the complete list of mime types. Remove the static caching of the types so that filters other than the first filter work. Use wp_get_mime_types() in do_enclose(). fixes #21299 #21594

Note: See TracTickets for help on using tickets.