Converting a BlobBuilder to string, in HTML5 Javascript

前端 未结 2 670
执笔经年
执笔经年 2021-01-24 04:42
          function blobToString(blob) {
             var reader = new FileReader();
             var d = \"\";
             reader.onloadend = function() {
                      


        
2条回答
  •  迷失自我
    2021-01-24 05:41

    it should not be reader.onloadend but rather reader.onloaded

    or try

    reader.onload = function (e) {
    e.target.result -> this is the data. 
    }
    

提交回复
热议问题