saving canvas locally in IE

前端 未结 2 1785
生来不讨喜
生来不讨喜 2021-01-05 04:15

Hi I want to save a canvas locally in IE.

  var img = canvas.toDataURL(\"image/png\").replace(\"image/png\", \"image/octet-stream\");

I cou

2条回答
  •  既然无缘
    2021-01-05 05:02

    Well, it looks like this doesn't work in IE either, but since you've not listed it, I'll provide an example. This uses the HTML5 download attribute (more here), and allows the user to click a link which then downloads a file.

    
    

提交回复
热议问题