javascript - Canvas toBlob is not recognized as a function in safari -
hi below code able download image in chrome& firefox not working in safari browser it's throwing below error
typeerror: 'undefined' not function (evaluating 'canvas.toblob(blobcallback('wallpaperdeae'))')
$("#save").click(function(){
function blobcallback(iconname) { return function (b) { var = document.getelementbyid('download'); a.download = iconname + ".jpg"; a.href = window.url.createobjecturl(b); } } canvas.toblob(blobcallback('wallpaperdeae')); });
thanks
i don't think toblob method supported in safari:
https://developer.mozilla.org/en-us/docs/web/api/htmlcanvaselement/toblob#browser_compatibility
according it's available in chrome 50+ , firefox (19+ basic support , 25+ image quality parameter) basic support in ie 10 , above.
so there's no support whatsoever safari.
Comments
Post a Comment