Saving image to local storage from canvas <p>Hi I am trying to save to file from canvas, but cannot <strong>name</strong> the file, this works but saves a file as "download" I would like give it any name. Any help is appreciated, lc.getImage gets image from canvas. </p> <pre><code> $('#download_btn').click(function() { var image = lc.getImage(); document.location.href = image.toDataURL("image/png").replace("image/png", "image/octet-stream"); }); </code></pre>