File Upload and EXIF in mobile Safari

前端 未结 3 1097
心在旅途
心在旅途 2021-01-18 01:10

As noted in these questions, there are cases where foto uploads on iOS have their geolocation and other EXIF metadata removed (in safari):

https://apple.stackexchang

3条回答
  •  攒了一身酷
    2021-01-18 02:08

    There are now methods to access raw tag information. This enables you to take your desired EXIF data, put it in a concealed form field, and send it with the real upload of the file.

    To get the EXIF:

    1. Create a button that calls a function to generate the file input and add a change handler.
    2. Then, In the file change handler use $(this).get(0).files to get the list of selected files.
    3. Parse the exif data and send the browse results to jsjpegmeta.

    This way you can get all the exif Information before its removed.

提交回复
热议问题