Is there a way to allow a user, after he has created a vector graph on a javascript svg canvas using a browser, to download this file to their local filesystem?
SVG
// save SVG $('#SVGsave').click(function(){ var a = document.createElement('a'); a.href = 'data:image/svg+xml;utf8,' + unescape($('#SVG')[0].outerHTML); a.download = 'plot.svg'; a.target = '_blank'; document.body.appendChild(a); a.click(); document.body.removeChild(a); });