Make WordPress Core

Opened 8 years ago

Closed 8 years ago

#36844 closed defect (bug) (duplicate)

Restrict upload MIME types for Customizer image controls to image MIME types

Reported by: neverything's profile neverything Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.4
Component: Customize Keywords:
Focuses: Cc:

Description

When using the Theme Customizer to upload an image in a image control, it doesn't restrict the file types that can be uploaded. For example, I can upload a video file or a pdf file, the file will be uploaded and inserted into the Media Library, then the Customizer will try to treat it like an image.

I think the best way around this would be to restrict uploads in the Customizer to images only.

There was a fix before Customizer controls in 3.5, ticket #22149

https://cldup.com/4FuRQSKxtf.png

Change History (3)

#1 @westonruter
8 years ago

  • Milestone changed from Awaiting Review to Future Release

It looks like the Media Manager allows you to upload and select a file that is not among the allowed file types. I tried uploading an MP3 when selecting a background image, and after uploading the image didn't appear in the library but it was selected in the attachment details and I could submit it. Uploads of the incorrect file type shouldn't be selected by default once the upload finishes.

#2 @swissspidy
8 years ago

Haven't there been any changes to Plupload in core lately in this regard? Don't know the ticket number off the top of my head.

#3 @ocean90
8 years ago

  • Component changed from Media to Customize
  • Milestone Future Release deleted
  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #33713.

Note: See TracTickets for help on using tickets.