Bug 239001
| Summary: | iOS File input accepts type not being respected and always uploads a jpeg | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Ant Dodds <anthony.dodds> |
| Component: | Forms | Assignee: | Nobody <webkit-unassigned> |
| Status: | NEW | ||
| Severity: | Normal | CC: | akeerthi, cdumez, sabouhallawa, thorton, webkit-bug-importer, wenson_hsieh |
| Priority: | P2 | Keywords: | InRadar |
| Version: | Other | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| See Also: | https://bugs.webkit.org/show_bug.cgi?id=238668 | ||
Ant Dodds
On iOS 15 devices given the following form
<form action="" method="POST" enctype="multipart/form-data">
<input type="file" name="uploaded-file[]" accept="image/heic, image/heif, image/png" multiple="multiple" />
<br >
<input name="submit" type="submit" value="Submit" />
</form>
When using the "Photo Library" option, images that are jpeg can be selected.
When submitting the form the reported mime type that is received server side is image/jpeg, which is not listed as an accepted format, the file data received is also jpeg not the accepted formats.
If I have saved the files to the device from the photos app and use "Choose files", jpeg files are still selectable, but we do get the correct file data and mime-types for heic/heif, and png files.
While there is a work around to get the correct file types we are looking for, getting people to do this isn't reasonable, the desired outcome for this would be if I as a user select a heic/heif for upload the system gets the correct file regardless of where the selection has been made, be this the photos app or choose files.
Thanks,
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/91807745>