Image preview before upload in IE and Chrome

前端 未结 7 2022
说谎
说谎 2021-02-14 19:51

I am trying to design a module in which I would like to show a preview of the image to the user before he uploads the image to database.

I have found a solution which wo

7条回答
  •  野性不改
    2021-02-14 20:32

    There's no cross-browser solution (even FileReader needs certain permissions in Firefox), only some workarounds for ie and firefox.

    You should do the conventional way, upload the image to a temp file and delete/save it depending on user confirmation

    Hope this helps

提交回复
热议问题